unittests/tests/widget.js
branchpopcorn-port
changeset 114 eda061f1aa75
parent 74 d7a7d7216371
child 119 29d6d634cbdf
equal deleted inserted replaced
113:ebfd0d17e427 114:eda061f1aa75
     8     this.ser = new IriSP.JSONSerializer(this.dt, "/url");
     8     this.ser = new IriSP.JSONSerializer(this.dt, "/url");
     9   } }
     9   } }
    10   );
    10   );
    11   
    11   
    12   test("test initialisation", function() {
    12   test("test initialisation", function() {
    13     var wid = new IriSP.Widget(this.Popcorn, {parent: "widget-div"}, this.ser);
    13     var config = {divId: "mydiv"};
    14     deepEqual(wid._config, {parent: "widget-div"}, "Check if the parent div is set correctly");
    14     var wid = new IriSP.Widget(this.Popcorn, config, this.ser);
       
    15     deepEqual(wid._config, config, "Check if the parent div is set correctly");
       
    16     ok(wid.selector, "Check if the jquery selector is set");
    15     
    17     
    16   });
    18   });
    17   
    19   
    18   
    20   
    19 };
    21 };