Merge pull request #1962 from aadijoshi/patch-1

Set fake timers before calling throttle
This commit is contained in:
Ilya Kantor 2020-06-16 19:37:29 +03:00 committed by GitHub
commit f1da3ee136
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,8 +7,8 @@ describe("throttle(f, 1000)", function() {
}
before(function() {
f1000 = throttle(f, 1000);
this.clock = sinon.useFakeTimers();
f1000 = throttle(f, 1000);
});
it("the first call runs now", function() {