Skip to content
This repository
Browse code

Changed tests based on changes in .recorded()

  • Loading branch information...
commit 41dd6162396e0b8458082e16aa44a4245869c435 1 parent a740e74
Ville Karavirta authored
4 test/unit/array.js
@@ -286,7 +286,7 @@ test("Array values", function() {
286 286 deepEqual( arr.value(5), "0");
287 287 ok(av.backward());
288 288 ok(av.backward());
289   - for (var i = 0; i < values.length; i++) {
  289 + for (i = 0; i < values.length; i++) {
290 290 deepEqual( arr.value(i), values[i], "Getting value of index " + i );
291 291 }
292 292 });
@@ -308,6 +308,7 @@ test("Test show/hide", function() {
308 308 av.step();
309 309 equal(arr.element.filter(":visible").size(), 0, "Array not visible after hide");
310 310 arr.hide();
  311 + av.step(); // need to add another step, since the empty last step is pruned
311 312 equal(arr.element.filter(":visible").size(), 0, "Array not visible after another hide");
312 313 av.recorded();
313 314 jQuery.fx.off = true;
@@ -315,6 +316,7 @@ test("Test show/hide", function() {
315 316 equal(arr.element.filter(":visible").size(), 0);
316 317 av.backward();
317 318 equal(arr.element.filter(":visible").size(), 0, "Undoing hiding hidden should keep it hidden");
  319 + console.log(arr.element.filter(":visible").size());
318 320 av.begin();
319 321 av.forward(); // redo hide
320 322 av.forward(); // redo show
1  test/unit/code.js
@@ -57,6 +57,7 @@
57 57 av.step();
58 58 equal(var1.element.filter(":visible").size(), 0, "Variable not visible after hide");
59 59 var1.hide();
  60 + av.step(); // need to add another step, since the empty last step is pruned
60 61 equal(var1.element.filter(":visible").size(), 0, "Variable not visible after another hide");
61 62 av.recorded();
62 63 jQuery.fx.off = true;
2  test/unit/graphicals.js
@@ -414,6 +414,7 @@
414 414 equal(Math.round(currBB.height), Math.round(origBB.height));
415 415 });
416 416
  417 + module("label", { });
417 418 test("Test Label show/hide", function() {
418 419 var av = new JSAV("emptycontainer"),
419 420 label = av.label("label");
@@ -431,6 +432,7 @@
431 432 av.step();
432 433 equal(label.element.filter(":visible").size(), 0, "Label not visible after hide");
433 434 label.hide();
  435 + av.step(); // need to add another step, since the empty last step is pruned
434 436 equal(label.element.filter(":visible").size(), 0, "Label not visible after another hide");
435 437 av.recorded();
436 438 jQuery.fx.off = true;
1  test/unit/tree.js
@@ -416,6 +416,7 @@ test("Test show/hide", function() {
416 416 av.step();
417 417 equal(tree.element.filter(":visible").size(), 0, "Tree not visible after hide");
418 418 tree.hide();
  419 + av.step(); // need to add another step, since the empty last step is pruned
419 420 equal(tree.element.filter(":visible").size(), 0, "Tree not visible after another hide");
420 421 av.recorded();
421 422 jQuery.fx.off = true;

0 comments on commit 41dd616

Please sign in to comment.
Something went wrong with that request. Please try again.