diff --git a/dom/animation/test/chrome.ini b/dom/animation/test/chrome.ini index 4001899a50cf..681adc3c3c37 100644 --- a/dom/animation/test/chrome.ini +++ b/dom/animation/test/chrome.ini @@ -6,6 +6,10 @@ prefs = gfx.omta.background-color=true layout.css.individual-transform.enabled=true layout.css.motion-path.enabled=true + layout.css.motion-path-basic-shapes.enabled=true + layout.css.motion-path-coord-box.enabled=true + layout.css.motion-path-offset-position.enabled=true + layout.css.motion-path-ray.enabled=true support-files = testcommon.js ../../imptests/testharness.js @@ -15,7 +19,6 @@ support-files = [chrome/test_animate_xrays.html] # file_animate_xrays.html needs to go in mochitest.ini since it is served # over HTTP -[chrome/test_keyframe_effect_xrays.html] [chrome/test_animation_observers_async.html] [chrome/test_animation_observers_sync.html] [chrome/test_animation_performance_warning.html] @@ -23,6 +26,7 @@ support-files = [chrome/test_animation_properties_display.html] [chrome/test_cssanimation_missing_keyframes.html] [chrome/test_generated_content_getAnimations.html] +[chrome/test_keyframe_effect_xrays.html] [chrome/test_mutation_observer_for_element_removal_in_shadow_tree.html] [chrome/test_running_on_compositor.html] [chrome/test_simulate_compute_values_failure.html] diff --git a/dom/animation/test/chrome/test_running_on_compositor.html b/dom/animation/test/chrome/test_running_on_compositor.html index 5fa1c89ea078..a57b7212731a 100644 --- a/dom/animation/test/chrome/test_running_on_compositor.html +++ b/dom/animation/test/chrome/test_running_on_compositor.html @@ -1221,6 +1221,32 @@ promise_test(async t => { 'offset-path:polygon() animation should be running on the compositor'); }, 'offset-path:polygon() animation runs on the compositor'); +promise_test(async t => { + const div = addDiv(t); + const animation = div.animate({ offsetPath: ['padding-box', + 'padding-box'] }, + 100 * MS_PER_SEC); + + await waitForAnimationReadyToRestyle(animation); + await waitForPaints(); + + assert_animation_is_running_on_compositor(animation, + 'offset-path:padding-box animation should be running on the compositor'); +}, 'offset-path:padding-box animation runs on the compositor'); + +promise_test(async t => { + const div = addDiv(t); + const animation = div.animate({ offsetPath: ['content-box', + 'content-box'] }, + 100 * MS_PER_SEC); + + await waitForAnimationReadyToRestyle(animation); + await waitForPaints(); + + assert_animation_is_running_on_compositor(animation, + 'offset-path:content-box animation should be running on the compositor'); +}, 'offset-path:content-box animation runs on the compositor'); + promise_test(async t => { const div = addDiv(t); const animation = div.animate({ offsetDistance: ['0%', '100%'] }, @@ -1290,6 +1316,29 @@ promise_test(async t => { 'new added offset-path animation should be running on the compositor'); }, 'offset-anchor animation runs on the compositor'); +promise_test(async t => { + const div = addDiv(t); + const animation = div.animate({ offsetPosition: ['0% 0%', '100% 100%'] }, + 100 * MS_PER_SEC); + + await waitForAnimationReadyToRestyle(animation); + await waitForPaints(); + + assert_animation_is_not_running_on_compositor(animation, + 'offset-position animation is not running on the compositor because ' + + 'offset-path is none'); + + const newAnim = div.animate({ offsetPath: ['None', 'None'] }, + 100 * MS_PER_SEC); + await waitForAnimationReadyToRestyle(newAnim); + await waitForPaints(); + + assert_animation_is_running_on_compositor(animation, + 'offset-position animation should be running on the compositor'); + assert_animation_is_running_on_compositor(newAnim, + 'new added offset-path animation should be running on the compositor'); +}, 'offset-position animation runs on the compositor'); + promise_test(async t => { const div = addDiv(t); const animation = div.animate({ translate: ['0px', '100px'],