Closed CreativeTechGuy closed 1 year ago
Base: 95.52% // Head: 95.53% // Increases project coverage by +0.00%
:tada:
Coverage data is based on head (
cf18928
) compared to base (ad1d43c
). Patch coverage: 100.00% of modified lines in pull request are covered.
:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.
For the record, I am preserving the existing behavior which passes clock.now
in the case where performance.now()
isn't available. But that should probably be changed too since that doesn't match the browser's behavior. Should we break out the function that is used to implement performance.now()
to be usable even when that method isn't mocked? That way requestAnimationFrame
's args could be accurate in all cases?
Should we break out the function that is used to implement performance.now() to be usable even when that method isn't mocked?
Yes, I think that makes perfect sense! Separate commit and separate test case :)
You got it @fatso83! New commit and updated tests. Hope you like it 😃
@fatso83 Let me know if the latest changes address all of your concerns. I think this is good to go!
Lockfile was changed from v2 to v1, probably not on purpose 🙂
@SimenB Oh no! I'm not even sure how that could have accidentally happened. I would have understood if it upgraded to v3 somehow, but downgraded? No clue! I blame GitHub Codespaces' auto-setup haha.
How would you like me to fix it? I definitely didn't intend to change anything in that file, I'm so sorry it got committed.
I wouldn't worry about it, it doesn't really matter. Just a bit of extra diff 👍
I tried to reproduce it with a fresh GitHub Codespace and instantly upon setup it converted it back to v2 so I have no clue what I did. I guess whoever does the next PR will likely (either intentionally or accidentally) upgrade it to v2 again! haha
Purpose (TL;DR)
Fix issue #454 by computing requestAnimationFrame args at the time when the callback is fired.