Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / forms / shadow-tree-exposure.html
blobc1b1eb8d52a52849fc72b2d68e01f42ec604167d
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3 <head>
4 <script src="../../resources/js-test.js"></script>
5 </head>
6 <body>
7 <p id="description"></p>
8 <div id="console"></div>
9 <script>
10 description("Test to make sure shadow nodes are not exposed.");
12 var container = document.createElement("p");
13 document.body.appendChild(container);
15 container.appendChild(document.createTextNode("Some text: "));
17 shouldBe("getSelection().anchorNode", "null");
18 shouldBe("getSelection().anchorOffset", "0");
19 shouldBe("getSelection().focusNode", "null");
20 shouldBe("getSelection().focusOffset", "0");
21 shouldBe("getSelection().isCollapsed", "true");
22 shouldBe("getSelection().rangeCount", "0");
24 shouldBe("getSelection().baseNode", "null");
25 shouldBe("getSelection().baseOffset", "0");
26 shouldBe("getSelection().extentNode", "null");
27 shouldBe("getSelection().extentOffset", "0");
28 shouldBe("getSelection().type", "'None'");
30 debug("\nAdd an input element.\n");
32 var input = document.createElement("input");
33 container.appendChild(input);
34 input.value = "text";
35 input.focus();
36 input.select();
38 shouldBe("getSelection().anchorNode", "container");
39 shouldBe("getSelection().anchorOffset", "1");
40 shouldBe("getSelection().focusNode", "container");
41 shouldBe("getSelection().focusOffset", "1");
42 shouldBe("getSelection().isCollapsed", "true");
43 shouldBe("getSelection().rangeCount", "1");
44 shouldBe("getSelection().getRangeAt(0).startContainer", "container");
45 shouldBe("getSelection().getRangeAt(0).startOffset", "1");
46 shouldBe("getSelection().getRangeAt(0).endContainer", "container");
47 shouldBe("getSelection().getRangeAt(0).endOffset", "1");
49 shouldBe("getSelection().baseNode", "container");
50 shouldBe("getSelection().baseOffset", "1");
51 shouldBe("getSelection().extentNode", "container");
52 shouldBe("getSelection().extentOffset", "1");
53 shouldBe("getSelection().type", "'Range'");
55 debug("\nAdd a textarea element.\n");
57 var textarea = document.createElement("textarea");
58 container.appendChild(textarea);
59 textarea.value = "text";
60 textarea.focus();
61 textarea.select();
63 shouldBe("getSelection().anchorNode", "container");
64 shouldBe("getSelection().anchorOffset", "2");
65 shouldBe("getSelection().focusNode", "container");
66 shouldBe("getSelection().focusOffset", "2");
67 shouldBe("getSelection().isCollapsed", "true");
68 shouldBe("getSelection().rangeCount", "1");
69 shouldBe("getSelection().getRangeAt(0).startContainer", "container");
70 shouldBe("getSelection().getRangeAt(0).startOffset", "2");
71 shouldBe("getSelection().getRangeAt(0).endContainer", "container");
72 shouldBe("getSelection().getRangeAt(0).endOffset", "2");
74 shouldBe("getSelection().baseNode", "container");
75 shouldBe("getSelection().baseOffset", "2");
76 shouldBe("getSelection().extentNode", "container");
77 shouldBe("getSelection().extentOffset", "2");
78 shouldBe("getSelection().type", "'Range'");
80 document.body.removeChild(container);
82 debug("");
83 </script>
84 </body>
85 </html>