+
+ $(".mkwsPager").unbind("DOMNodeInserted DOMNodeRemoved propertychange");
+ });
+ });
+});
+
+
+describe("Check record list", function () {
+ it("got a record", function () {
+ var linkaddr = "div.mkwsRecords div.record:nth-child(1) a";
+ var waitcount = 2;
+
+ /*
+ // wait for new records, propertychange is for IE8
+ $("div.mkwsRecords").bind("DOMNodeInserted propertychange", function () {
+ waitcount++;
+ debug("DOM DOMNodeInserted:" + waitcount + " " + $("div.mkwsRecords div.record").length);
+ });
+ $("div.mkwsRecords").bind("DOMNodeRemoved", function () {
+ waitcount++;
+ debug("DOM DOMNodeRemoved:" + waitcount + " " + $("div.mkwsRecords div.record").length);
+ });
+ */
+
+ waitsFor(function () {
+ // remove + insert node: must be at least 2
+ return waitcount >= 2 && $(linkaddr).length > 0;
+ }, "wait until we see a new record: " + waitcount, 2.2 * jasmine_config.second);
+
+ runs(function () {
+ expect(waitcount).toBeGreaterThan(0);
+ // $("div.mkwsRecords").unbind("DOMNodeInserted DOMNodeRemoved");