OLD | NEW |
1 library SVG3Test; | 1 library SVG3Test; |
2 import '../../pkg/unittest/lib/unittest.dart'; | 2 import '../../pkg/unittest/lib/unittest.dart'; |
3 import '../../pkg/unittest/lib/html_config.dart'; | 3 import '../../pkg/unittest/lib/html_config.dart'; |
4 import 'dart:html'; | 4 import 'dart:html'; |
| 5 import 'dart:svg'; |
5 | 6 |
6 // Test that SVG elements have the operations advertised through all the IDL | 7 // Test that SVG elements have the operations advertised through all the IDL |
7 // interfaces. This is a 'duck typing' test, and does not explicitly use 'is' | 8 // interfaces. This is a 'duck typing' test, and does not explicitly use 'is' |
8 // checks on the expected interfaces (that is in SVGTest2). | 9 // checks on the expected interfaces (that is in SVGTest2). |
9 | 10 |
10 main() { | 11 main() { |
11 | 12 |
12 var isString = predicate((x) => x is String, 'is a String'); | 13 var isString = predicate((x) => x is String, 'is a String'); |
13 var isStringList = predicate((x) => x is List<String>, 'is a List<String>'); | 14 var isStringList = predicate((x) => x is List<String>, 'is a List<String>'); |
14 var isSVGMatrix = predicate((x) => x is SVGMatrix, 'is a SVGMatrix'); | 15 var isSVGMatrix = predicate((x) => x is SVGMatrix, 'is a SVGMatrix'); |
15 var isSVGAnimatedBoolean = | 16 var isSVGAnimatedBoolean = |
16 predicate((x) => x is SVGAnimatedBoolean, 'is an SVGAnimatedBoolean'); | 17 predicate((x) => x is SVGAnimatedBoolean, 'is an SVGAnimatedBoolean'); |
17 var isSVGAnimatedString = | 18 var isSVGAnimatedString = |
18 predicate((x) => x is SVGAnimatedString, 'is an SVGAnimatedString'); | 19 predicate((x) => x is SVGAnimatedString, 'is an SVGAnimatedString'); |
19 var isSVGRect = predicate((x) => x is SVGRect, 'is a SVGRect'); | 20 var isSVGRect = predicate((x) => x is SVGRect, 'is a SVGRect'); |
20 var isSVGAnimatedTransformList = | 21 var isSVGAnimatedTransformList = |
21 predicate((x) => x is SVGAnimatedTransformList, | 22 predicate((x) => x is SVGAnimatedTransformList, |
22 'is an SVGAnimatedTransformList'); | 23 'is an SVGAnimatedTransformList'); |
23 var isCSSStyleDeclaration = | 24 var isCSSStyleDeclaration = |
24 predicate((x) => x is CSSStyleDeclaration, 'is a CSSStyleDeclaration'); | 25 predicate((x) => x is CSSStyleDeclaration, 'is a CSSStyleDeclaration'); |
25 var isCSSValue = predicate((x) => x is CSSValue, 'is a CSSValue'); | 26 var isCSSValue = predicate((x) => x is CSSValue, 'is a CSSValue'); |
26 | 27 |
27 insertTestDiv() { | 28 insertTestDiv() { |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 | 135 |
135 testRect('rect_SVGTests', checkSVGTests); | 136 testRect('rect_SVGTests', checkSVGTests); |
136 testRect('rect_SVGLangSpace', checkSVGLangSpace); | 137 testRect('rect_SVGLangSpace', checkSVGLangSpace); |
137 testRect('rect_SVGExternalResourcesRequired', | 138 testRect('rect_SVGExternalResourcesRequired', |
138 checkSVGExternalResourcesRequired); | 139 checkSVGExternalResourcesRequired); |
139 testRect('rect_SVGStylable', checkSVGStylable); | 140 testRect('rect_SVGStylable', checkSVGStylable); |
140 testRect('rect_SVGLocatable', checkSVGLocatable); | 141 testRect('rect_SVGLocatable', checkSVGLocatable); |
141 testRect('rect_SVGTransformable', checkSVGTransformable); | 142 testRect('rect_SVGTransformable', checkSVGTransformable); |
142 | 143 |
143 } | 144 } |
OLD | NEW |