Skip to content

Commit

Permalink
Merge pull request jashkenas#1249 from braddunbar/throttle
Browse files Browse the repository at this point in the history
Prevent false negatives for _.throttle tests.
  • Loading branch information
jashkenas committed Aug 7, 2013
2 parents ccd7a20 + de60b9a commit d67868d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -239,10 +239,10 @@ $(document).ready(function() {

var time = new Date;
while (new Date - time < 350) throttledIncr();
ok(counter === 3);
ok(counter <= 3);

_.delay(function() {
equal(counter, 4);
ok(counter <= 4);
start();
}, 200);
});
Expand Down

0 comments on commit d67868d

Please sign in to comment.