Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1048)

Side by Side Diff: third_party/WebKit/LayoutTests/animations/svg/clear-svg-animation-effects.html

Issue 2975793004: Move animation svg tests to own subdirectory (Closed)
Patch Set: Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <script src="../resources/testharness.js"></script> 1 <script src="../../resources/testharness.js"></script>
2 <script src="../resources/testharnessreport.js"></script> 2 <script src="../../resources/testharnessreport.js"></script>
3 <svg> 3 <svg>
4 <stop id="target" offset="1"/> 4 <stop id="target" offset="1"/>
5 </svg> 5 </svg>
6 <script> 6 <script>
7 var asyncHandle = async_test('SVG Attributes should return to their base values after animations have stopped applying.'); 7 var asyncHandle = async_test('SVG Attributes should return to their base values after animations have stopped applying.');
8 8
9 var animation = target.animate([ 9 var animation = target.animate([
10 {'svg-offset': '0'}, 10 {'svg-offset': '0'},
11 {'svg-offset': '0.5'}, 11 {'svg-offset': '0.5'},
12 ], 1000); 12 ], 1000);
13 animation.pause(); 13 animation.pause();
14 animation.currentTime = 500; 14 animation.currentTime = 500;
15 15
16 requestAnimationFrame(() => { 16 requestAnimationFrame(() => {
17 asyncHandle.step(() => { 17 asyncHandle.step(() => {
18 assert_equals(target.offset.animVal, 0.25, 'Animation is in effect.'); 18 assert_equals(target.offset.animVal, 0.25, 'Animation is in effect.');
19 }); 19 });
20 animation.cancel(); 20 animation.cancel();
21 requestAnimationFrame(() => { 21 requestAnimationFrame(() => {
22 asyncHandle.step(() => { 22 asyncHandle.step(() => {
23 assert_equals(target.offset.animVal, 1, 'Animation is no longer in effect. '); 23 assert_equals(target.offset.animVal, 1, 'Animation is no longer in effect. ');
24 }); 24 });
25 asyncHandle.done(); 25 asyncHandle.done();
26 }); 26 });
27 }); 27 });
28 </script> 28 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698