mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-14 22:05:44 +00:00
Bug 1444177 - Tweak expected restyle count for the test case where finite animation is unthrottled in out-of-view element. r=birtles
It might be possible that the animation does not start being restyled in the
initial frame. Eventually we should drop tweakExpectedRestyleCount in bug
1425778
and replace it with a function that waits for animation.ready and waits
to start being restyled something like this;
async function waitForAnimationReadyToBeRestyled(aAnimation) {
await aAnimation.ready;
if (animationStartsRightNow(aAnimation)) {
await waitForFrame();
}
}
MozReview-Commit-ID: ByN25hMAK76
--HG--
extra : rebase_source : 6dd3a44661905ffff7bce748540572df2d40425b
This commit is contained in:
parent
1c1a60c08d
commit
df1a0e7203
@ -628,8 +628,10 @@ waitForAllPaints(() => {
|
||||
await animation.ready;
|
||||
ok(!SpecialPowers.wrap(animation).isRunningOnCompositor);
|
||||
|
||||
var markers = await observeStyling(20);
|
||||
is(markers.length, 20,
|
||||
const expectedRestyleCount = tweakExpectedRestyleCount(animation, 20);
|
||||
|
||||
var markers = await observeStyling(expectedRestyleCount);
|
||||
is(markers.length, expectedRestyleCount,
|
||||
'Finite transform animation in out-of-view element should never be ' +
|
||||
'throttled');
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user