diff -r 7071ccbc315a -r a9c5eeca190c unittests/tests/module.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/unittests/tests/module.js Wed Dec 14 14:56:40 2011 +0100 @@ -0,0 +1,17 @@ +/* test module for base widgets */ +function test_module() { + module("Base module testing", + {setup : function() { + this.Popcorn = Popcorn("#popcorn-div"); + + this.dt = new IriSP.DataLoader(); + this.ser = new IriSP.JSONSerializer(this.dt, "/url"); + } } + ); + + test("test initialisation", function() { + var config = { a : 540}; + var mod = new IriSP.Module(this.Popcorn, config, this.ser); + deepEqual(mod._config, config, "Check that config is copied correctly"); + }); +};