5 div { font-size:
8px; }
8 <script src=
"../../resources/js-test.js"></script>
10 description('Test clip-path IRIs');
12 function computedStyle(property
, value
) {
13 var div
= document
.createElement("div");
14 document
.body
.appendChild(div
);
15 div
.style
.setProperty(property
, value
);
16 var computedValue
= getComputedStyle(div
).getPropertyValue(property
);
17 document
.body
.removeChild(div
);
21 function innerStyle(property
, value
) {
22 var div
= document
.createElement("div");
23 div
.style
.setProperty(property
, value
);
24 return div
.style
.getPropertyValue(property
);
27 function testComputed(property
, value
, expected
) {
28 shouldBeEqualToString('computedStyle("' + property
+ '", "' + value
+ '")', expected
);
31 function testInner(property
, value
, expected
) {
32 if (expected
=== null)
33 shouldBeNull('innerStyle("' + property
+ '", "' + value
+ '")');
35 shouldBeEqualToString('innerStyle("' + property
+ '", "' + value
+ '")', expected
);
38 testInner("-webkit-clip-path", "url(#clip1)", "url(#clip1)");
39 testInner("-webkit-clip-path", "url(clip.svg#clip1)", "url(clip.svg#clip1)");
41 testComputed("-webkit-clip-path", "url(#clip1)", "url(#clip1)");
42 testComputed("-webkit-clip-path", "url(clip.svg#clip1)", "url(clip.svg#clip1)");