Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / events / touch / gesture / touch-gesture-scroll-div-removed.html
blob43ba59a242ec5c6d8efbfaef2e1c0553dc53e32a
1 <!DOCTYPE HTML>
2 <html>
3 <head>
4 <script src="../../../../resources/js-test.js"></script>
5 <style>
6 #container {
7 width: 100px;
8 height: 100px;
9 position: relative;
10 overflow-y: scroll;
11 background: white;
14 ::-webkit-scrollbar {
15 width: 0px;
16 height: 0px;
19 .box {
20 width: 100px;
21 height: 100px;
22 background: red;
23 padding: 0px;
24 margin: 0px;
27 td {
28 padding: 0px;
30 </style>
31 </head>
32 <body style="margin:0">
33 <div id="container">
34 <table border="0" cellspacing="0px" id="tablefoo">
35 <tr>
36 <td><div id="redbox" class="box" style="background-color:red;"></div></td>
37 </tr>
38 <tr>
39 <td><div id="greenbox" class="box" style="background-color:green;"></div></td>
40 </tr>
41 </table>
42 </div>
44 <p id="description"></p>
45 <div id="console"></div>
46 <script>
48 if (window.testRunner)
49 testRunner.dumpAsText();
51 function runTest()
53 if (!window.eventSender) {
54 debug("This test requires DumpRenderTree.");
55 return;
58 description('Verifies that deleting the element being gesture-scrolled immediately before sending the scroll-end does not cause a crash. The test passes if it does not crash.');
60 debug("starting gesture scroll");
61 eventSender.gestureScrollBegin(10, 10);
62 eventSender.gestureScrollUpdate(0, -5);
64 debug("deleting the targeted element");
65 var target = document.getElementById('redbox');
66 target.parentNode.removeChild(target);
67 target = null;
68 gc();
70 debug("dispatching the GestureScrollEnd");
71 eventSender.gestureScrollEnd(0, 0);
74 runTest();
75 </script>
76 </body>
77 </html>