|
27 | 27 | import org.htmlunit.html.Keyboard; |
28 | 28 | import org.htmlunit.junit.BrowserRunner; |
29 | 29 | import org.htmlunit.junit.annotation.Alerts; |
30 | | -import org.htmlunit.junit.annotation.NotYetImplemented; |
31 | 30 | import org.junit.Test; |
32 | 31 | import org.junit.runner.RunWith; |
33 | 32 |
|
@@ -159,41 +158,6 @@ public void eventOnBlur() throws Exception { |
159 | 158 | assertEquals(expectedAlerts, collectedAlerts); |
160 | 159 | } |
161 | 160 |
|
162 | | - /** |
163 | | - * Test for event bubbling in IE. |
164 | | - * @throws Exception if the test fails |
165 | | - */ |
166 | | - @Test |
167 | | - @NotYetImplemented // TODO: in IE no click event can be registered for the window |
168 | | - @Alerts({"span bubbling", "div", "div bubbling"}) |
169 | | - public void ie_EventBubbling() throws Exception { |
170 | | - final String content = DOCTYPE_HTML |
171 | | - + "<html><head><title>foo</title>\n" |
172 | | - + "<script>\n" |
173 | | - + "function t(_s) {\n" |
174 | | - + " return function() { alert(_s) };\n" |
175 | | - + "}\n" |
176 | | - + "function init() {\n" |
177 | | - + " window.attachEvent('onclick', t('window bubbling'));\n" |
178 | | - + " var oDiv = document.getElementById('theDiv');\n" |
179 | | - + " oDiv.attachEvent('onclick', t('div bubbling'));\n" |
180 | | - + " var oSpan = document.getElementById('theSpan');\n" |
181 | | - + " oSpan.attachEvent('onclick', t('span bubbling'));\n" |
182 | | - + "}\n" |
183 | | - + "</script>\n" |
184 | | - + "</head><body onload='init()'>\n" |
185 | | - + "<div onclick=\"alert('div')\" id='theDiv'>\n" |
186 | | - + "<span id='theSpan'>blabla</span>\n" |
187 | | - + "</div>\n" |
188 | | - + "</body></html>"; |
189 | | - |
190 | | - final List<String> collectedAlerts = new ArrayList<>(); |
191 | | - final HtmlPage page = loadPage(content, collectedAlerts); |
192 | | - page.getHtmlElementById("theSpan").click(); |
193 | | - |
194 | | - assertEquals(getExpectedAlerts(), collectedAlerts); |
195 | | - } |
196 | | - |
197 | 161 | /** |
198 | 162 | * Test for bug 1976960: what happens with different return values at different levels? |
199 | 163 | * @throws Exception if an error occurs |
|
0 commit comments