Debian Codegraph @

test_non_regression/fail/na/animation/animate-dom-02-f.svg

raw
1 <svg id="svg-root" width="100%" height="100%"
2 viewBox="0 0 480 360" xmlns="http://www.w3.org/2000/svg"
3 xmlns:xlink="http://www.w3.org/1999/xlink">
4 <!--======================================================================-->
5 <!--= Copyright 2008 World Wide Web Consortium, (Massachusetts =-->
6 <!--= Institute of Technology, European Research Consortium for =-->
7 <!--= Informatics and Mathematics (ERCIM), Keio University). =-->
8 <!--= All Rights Reserved. =-->
9 <!--= See http://www.w3.org/Consortium/Legal/. =-->
10 <!--======================================================================-->
11 <d:SVGTestCase xmlns:d="http://www.w3.org/2000/02/svg/testsuite/description/"
12 template-version="1.3" reviewer="DAS" author="CM" status="accepted"
13 version="$Revision: 1.7 $" testname="$RCSfile: animate-dom-02-f.svg,v $">
14 <d:testDescription xmlns="http://www.w3.org/1999/xhtml" href="http://www.w3.org/TR/SVG11/animate.html#InterfaceSVGAnimationElement">
15 <p>
16 This tests that the methods on the ElementTimeControl
17 interface return the undefined value, since the IDL
18 operations are declared to return void.
19 </p>
20 <p>
21 After the loading the document, a rectangle is shown
22 indicating whether all four methods from the ElementTimeControl
23 interface returned undefined when invoked. The rectangle
24 is black if the test did not run, red if the test failed
25 and green if the test succeeded.
26 </p>
27 </d:testDescription>
28 <d:operatorScript xmlns="http://www.w3.org/1999/xhtml">
29 <p>
30 Run the test. No interaction required.
31 </p>
32 </d:operatorScript>
33 <d:passCriteria xmlns="http://www.w3.org/1999/xhtml">
34 <p>
35 The test is passed if the rectangle is green.
36 </p>
37 </d:passCriteria>
38 </d:SVGTestCase>
39 <title id="test-title">$RCSfile: animate-dom-02-f.svg,v $</title>
40 <defs>
41 <font-face
42 font-family="SVGFreeSansASCII"
43 unicode-range="U+0-7F">
44 <font-face-src>
45 <font-face-uri xlink:href="../resources/SVGFreeSans.svg#ascii"/>
46 </font-face-src>
47 </font-face>
48 </defs>
49 <g id="test-body-content" font-family="SVGFreeSansASCII,sans-serif" font-size="18">
50
51 <text x='10' y='30'>Testing ElementTimeControl method return values</text>
52
53 <rect id='r' x='10' y='50' width='50' height='50'/>
54 <animate id='a' attributeName='display' values='inline; inline' dur='10s'/>
55 <animate attributeName='display' values='inline; inline' onbegin='f()' dur='10s'/>
56
57 <script><![CDATA[
58 function f() {
59 var a = document.getElementById('a');
60 var b = false;
61 try {
62 b = typeof a.beginElement() == 'undefined'
63 && typeof a.beginElementAt(100) == 'undefined'
64 && typeof a.endElement() == 'undefined'
65 && typeof a.endElementAt(200) == 'undefined';
66 } catch (e) {
67 }
68 document.getElementById('r').setAttribute('fill', b ? 'green' : 'red');
69 }
70 ]]></script>
71 </g>
72 <g font-family="SVGFreeSansASCII,sans-serif" font-size="32">
73 <text id="revision" x="10" y="340" stroke="none"
74 fill="black">$Revision: 1.7 $</text>
75 </g>
76 <rect id="test-frame" x="1" y="1" width="478" height="358" fill="none" stroke="#000"/>
77 <!-- comment out this watermark once the test is approved --><!--
78 <g id="draft-watermark">
79 <rect x="1" y="1" width="478" height="20" fill="red" stroke="black" stroke-width="1"/>
80 <text font-family="SVGFreeSansASCII,sans-serif" font-weight="bold" font-size="20" x="240"
81 text-anchor="middle" y="18" stroke-width="0.5" stroke="black" fill="white">DRAFT</text>
82 </g>-->
83 </svg>