Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / events / touch / touch-handler-assert-input-range.html
blobac04abee7fcf385cdf16f25dcbe06abbf2e0b6b0
1 <!DOCTYPE HTML>
2 <html>
3 <head>
4 <style>
5 </style>
6 <script src="../../../resources/js-test.js"></script>
7 </head>
8 <body>
9 <p id="description"></p>
10 <div id="console"></div>
11 <iframe id="frame" src='data:text/html,<input type="range"></input>'></iframe>
12 <script>
13 description("Make sure we don't ASSERT when an input element with a built-in touch handler is deleted after previously being removed from the document - crbug.com/285299.");
15 window.jsTestIsAsync = true;
17 var rects;
18 document.getElementById('frame').addEventListener('load', function() {
19 // Verify we actually have a hit rect on the page.
20 if (window.internals) {
21 rects = window.internals.touchEventTargetLayerRects(document);
22 shouldBe("rects.length", "1");
25 document.getElementById("frame").remove();
26 if (window.internals) {
27 rects = window.internals.touchEventTargetLayerRects(document);
28 shouldBe("rects.length", "0");
30 window.setTimeout(function() {
31 gc();
32 finishJSTest();
33 }, 0);
34 });
36 </script>
37 </body>
38 </html>