tween.js icon indicating copy to clipboard operation
tween.js copied to clipboard

Add test for calling a tween's update() method with no arguments.

Open trusktr opened this issue 5 years ago • 1 comments

https://github.com/tweenjs/tween.js/pull/558 allows tween.update() to be called without a time argument, and existing tests pass. We should also add a unit test for the case of calling it without the time arg.

trusktr avatar Sep 24 '20 21:09 trusktr

from @mikebolt (https://github.com/tweenjs/tween.js/pull/558#issuecomment-698674691)

It's potentially difficult to test because the current time will change depending on when the test is run, and the tests need to run in both node and browsers. You could copy the "now" polyfill that we made. Also, the test might be flaky due to the clock advancing by 1ms, so give it a buffer of 5ms or something.

trusktr avatar Oct 06 '20 04:10 trusktr

Closed in https://github.com/tweenjs/tween.js/pull/605

trusktr avatar Apr 23 '23 06:04 trusktr