unittests/tests/widgets/annotationsWidget.js
branchtweet-widget
changeset 284 cbb17aa3361c
parent 234 43b198dc932d
child 309 49c2b9e63591
equal deleted inserted replaced
283:39e6707ca72b 284:cbb17aa3361c
    27   test("test widget initialization", function() {  
    27   test("test widget initialization", function() {  
    28     var widget = new IriSP.AnnotationsWidget(this.Popcorn, this.config, this.ser);    
    28     var widget = new IriSP.AnnotationsWidget(this.Popcorn, this.config, this.ser);    
    29     widget.draw();
    29     widget.draw();
    30 
    30 
    31     equal(widget.selector.children(".Ldt-AnnotationsWidget").length, 1, "test if the div has been added correctly");
    31     equal(widget.selector.children(".Ldt-AnnotationsWidget").length, 1, "test if the div has been added correctly");
    32     equal(widget.selector.children(".Ldt-AnnotationsWidget").find(".Ldt-SaKeyword").length, 1, "test if sub-div has been added correctly");
       
    33   });
    32   });
    34   
    33   
    35   test("test annotation display function", function() {
    34   test("test annotation display function", function() {
    36     var widget = new IriSP.AnnotationsWidget(this.Popcorn, this.config, this.ser);    
    35     var widget = new IriSP.AnnotationsWidget(this.Popcorn, this.config, this.ser);    
    37     widget.draw();
    36     widget.draw();