Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / css / getPropertyValue-webkit-text-stroke.html
blob6ba0610259a0df312e3594e7a65f4fbfd8e017c6
1 <!DOCTYPE HTML>
2 </html>
3 <head>
4 <title>-webkit-text-stroke shorthand getPropertyValue test</title>
5 <style>
6 .test {
7 width: 5em;
8 height: 10em;
10 </style>
11 <script src="../../resources/js-test.js"></script>
12 <script>
13 if (window.testRunner)
14 testRunner.dumpAsText();
15 </script>
16 </head>
17 <body>
18 <div id="text-stroke1" class="test" style="-webkit-text-stroke: thin red;"></div>
19 <div id="text-stroke2" class="test" style="-webkit-text-stroke: green;"></div>
20 <div id="text-stroke3" class="test" style="-webkit-text-stroke: thin;"></div>
21 <div id="text-stroke4" class="test" style="-webkit-text-stroke: 1px red;"></div>
22 <div id="text-stroke5" class="test" style="-webkit-text-stroke-width: 1px; -webkit-text-stroke-color: black;"></div>
23 <div id="text-stroke6" class="test" style="-webkit-text-stroke: foo;"></div>
24 <div id="text-stroke7" class="test" style="-webkit-text-stroke-color: green;"></div>
25 <script>
26 description("<a href=\"https://bugs.webkit.org/show_bug.cgi?id=111018\">Bug 111018: getPropertyValue for -webkit-text-stroke returns null, should compute the shorthand value</a>");
28 function webkitTextStrokeValue(id) {
29 var element = document.getElementById(id);
30 return element.style.getPropertyValue("-webkit-text-stroke");
33 shouldBeEqualToString('webkitTextStrokeValue("text-stroke1")', 'thin red');
34 shouldBeEqualToString('webkitTextStrokeValue("text-stroke2")', 'green');
35 shouldBeEqualToString('webkitTextStrokeValue("text-stroke3")', 'thin');
36 shouldBeEqualToString('webkitTextStrokeValue("text-stroke4")', '1px red');
37 shouldBeEqualToString('webkitTextStrokeValue("text-stroke5")', '1px black');
38 debug("NOTE: 'foo' is an illegal CSS value for '-webkit-text-stroke'.");
39 shouldBeEqualToString('webkitTextStrokeValue("text-stroke6")', "");
40 debug("NOTE: If only few longhand properties are specified, getPropertyValue for shorthand property returns empty string.")
41 shouldBeEqualToString('webkitTextStrokeValue("text-stroke7")', "");
42 </script>
43 </body>
44 </html>