Bug 1366934 - Remove validation of transitioncancel/animationcanel event order tests. r=hiro

The animationcancel and transitioncancel is not absolute order when elapsed time
of siblings cancel event is same. So we will not need to check the order of
cancel events.

MozReview-Commit-ID: 8fiwgcvTlwE

--HG--
extra : rebase_source : 055c4d47554753f79d17eae563dea1ff6636e60b
This commit is contained in:
Mantaroh Yoshinaga 2017-06-20 14:31:41 +09:00
parent b3c118e299
commit a7a27655d4
2 changed files with 18 additions and 11 deletions

View File

@ -41,9 +41,6 @@ to mochitest command.
* console support bug 1352669
* test_bug413958.html `monitorConsole` [3]
* test_parser_diagnostics_unprintables.html [550]
* Transition support:
* Events:
* test_animations_event_order.html [2]
* Unimplemented \@font-face descriptors:
* test_font_face_parser.html `font-language-override`: bug 1355364 [8]
* keyword values should be preserved in \@font-face bug 1355368

View File

@ -628,8 +628,6 @@ divs = [];
// 4j. Test sorting transitions with cancel
// The order of transitioncancel is based on StyleManager.
// So this test looks like wrong result at a glance. However
// the gecko will cancel div1's transition before div2 in this case.
divs = [ document.createElement('div'),
document.createElement('div') ];
@ -648,16 +646,22 @@ getComputedStyle(divs[0]).marginLeft;
advance_clock(0);
advance_clock(5 * 1000);
divs.forEach(div => div.style.display = 'none' );
getComputedStyle(divs[0]).display;
divs.forEach(div => {
div.style.display = 'none';
// The transitioncancel event order is not absolute when firing siblings
// transitioncancel on same elapsed time.
// Force to flush style for the element so that the transition on the element
// iscancelled and corresponding cancel event is queued respectively.
getComputedStyle(div).display;
});
advance_clock(10 * 1000);
checkEventOrder([ divs[0], 'transitionrun' ],
[ divs[1], 'transitionrun' ],
[ divs[1], 'transitionstart' ],
[ divs[0], 'transitionstart' ],
[ divs[1], 'transitioncancel' ],
[ divs[0], 'transitioncancel' ],
[ divs[1], 'transitioncancel' ],
'Simultaneous transitionrun/start/cancel on siblings');
divs.forEach(div => div.remove());
@ -682,14 +686,20 @@ getComputedStyle(divs[0]).animation; // flush
advance_clock(0); // divs[1]'s animation start
advance_clock(5 * 1000); // divs[0]'s animation start
divs.forEach(div => div.style.display = 'none' );
getComputedStyle(divs[0]).display;
divs.forEach(div => {
div.style.display = 'none';
// The animationcancel event order is not absolute when firing siblings
// animationcancel on same elapsed time.
// Force to flush style for the element so that the transition on the element
// iscancelled and corresponding cancel event is queued respectively.
getComputedStyle(div).display;
});
advance_clock(10 * 1000);
checkEventOrder([ divs[1], 'animationstart' ],
[ divs[0], 'animationstart' ],
[ divs[1], 'animationcancel' ],
[ divs[0], 'animationcancel' ],
[ divs[1], 'animationcancel' ],
'Simultaneous animationcancel on siblings');
SpecialPowers.DOMWindowUtils.restoreNormalRefresh();