Commit 14a9a8bd 14a9a8bd3a846c9a16f1d947f627cb48a6ecd6a9 by Nicolas Perriault

better check for planned tests

1 parent 90bec9fa
...@@ -830,9 +830,10 @@ Tester.prototype.done = function done(planned) { ...@@ -830,9 +830,10 @@ Tester.prototype.done = function done(planned) {
830 if (arguments.length > 0) { 830 if (arguments.length > 0) {
831 this.casper.warn('done() `planned` arg is deprecated as of 1.1'); 831 this.casper.warn('done() `planned` arg is deprecated as of 1.1');
832 } 832 }
833 if (this.currentSuite && this.currentSuite.planned !== this.executed) { 833 if (this.currentSuite && this.currentSuite.planned && this.currentSuite.planned !== this.executed) {
834 this.dubious(this.currentSuite.planned, this.executed); 834 this.dubious(this.currentSuite.planned, this.executed);
835 } else if (planned && planned !== this.executed) { 835 } else if (planned && planned !== this.executed) {
836 // BC
836 this.dubious(planned, this.executed); 837 this.dubious(planned, this.executed);
837 } 838 }
838 if (this.currentSuite) { 839 if (this.currentSuite) {
......