We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c7a2352 commit 92f2fbaCopy full SHA for 92f2fba
test/unit/queue.js
@@ -80,11 +80,15 @@ describe('FlushQueue', function () {
80
81
it('can invoke events after a delay', function () {
82
var clock = sinon.useFakeTimers();
83
- queue.push(spy);
84
- queue.flush(100);
85
- expect(spy.called).to.equal(false);
86
- clock.tick(100);
87
- expect(spy.called).to.equal(true);
+ try {
+ queue.push(spy);
+ queue.flush(100);
+ expect(spy.called).to.equal(false);
+ clock.tick(100);
88
+ expect(spy.called).to.equal(true);
89
+ } finally {
90
+ clock.restore();
91
+ }
92
});
93
94
0 commit comments