1 <?xml version=
"1.0" encoding=
"utf-8" standalone=
"no"?>
2 <svg xmlns='http://www.w3.org/
2000/svg'
>
3 <circle cx='
0' cy='
50' r='
20' fill='orange' id='testCircle'
>
4 <animate attributeName='cx' attributeType='XML' begin='indefinite' end='indefinite' dur='
10s' repeatCount='indefinite'
from=
"10" to=
"200" id='dTripper'
fill=
"freeze"/>
6 <text y=
"130" x=
"20">This test verifies the animation behaviour of beginElement in SVG. See
<a href=
"https://bugs.webkit.org/show_bug.cgi?id=26019">bug
26019</a></text>
7 <text y=
"150" x=
"20" id=
"console"/>
10 animatedElement = document.getElementById(
"dTripper");
11 animatedElement.setAttribute(
"to",
420);
12 animatedElement.beginElement();
13 setTimeout(beginElement,
0);
15 function beginElement()
17 animatedElement.setAttribute(
"to",
420);
18 animatedElement.beginElement();
19 setTimeout(dumpResult,
0);
24 var console = document.getElementById(
"console");
25 var cx = document.getElementById(
"testCircle").getAttribute(
"cx");
27 console.appendChild(document.createTextNode(
"Failed (cx was not animated)"));
29 console.appendChild(document.createTextNode(
"Passed"));
30 if (window.testRunner)
31 testRunner.notifyDone();
34 if (window.testRunner) {
35 testRunner.dumpAsText();
36 testRunner.waitUntilDone();