| OLD | NEW |
| 1 suite('player-finish-event', function() { | 1 suite('player-finish-event', function() { |
| 2 setup(function() { | 2 setup(function() { |
| 3 this.element = document.createElement('div'); | 3 this.element = document.createElement('div'); |
| 4 document.documentElement.appendChild(this.element); | 4 document.documentElement.appendChild(this.element); |
| 5 this.player = this.element.animate([], 1000); | 5 this.player = this.element.animate([], 1000); |
| 6 }); | 6 }); |
| 7 teardown(function() { | 7 teardown(function() { |
| 8 if (this.element.parent) | 8 if (this.element.parent) |
| 9 this.element.removeChild(this.target); | 9 this.element.removeChild(this.target); |
| 10 }); | 10 }); |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 this.player.removeEventListener('finish', toRemove); | 70 this.player.removeEventListener('finish', toRemove); |
| 71 this.player.onfinish = function() { | 71 this.player.onfinish = function() { |
| 72 assert.equal(count, 3); | 72 assert.equal(count, 3); |
| 73 done(); | 73 done(); |
| 74 }; | 74 }; |
| 75 tick(0); | 75 tick(0); |
| 76 this.player.cancel(); | 76 this.player.cancel(); |
| 77 tick(1000); | 77 tick(1000); |
| 78 }); | 78 }); |
| 79 }); | 79 }); |
| OLD | NEW |