diff --git a/src/test/java/org/htmlunit/html/parser/MalformedHtmlTest.java b/src/test/java/org/htmlunit/html/parser/MalformedHtmlTest.java index cb3ef1a8337..1066b9e3748 100644 --- a/src/test/java/org/htmlunit/html/parser/MalformedHtmlTest.java +++ b/src/test/java/org/htmlunit/html/parser/MalformedHtmlTest.java @@ -1419,4 +1419,27 @@ public void incompleteEntities() throws Exception { assertEquals(getExpectedAlerts()[0], getMockWebConnection().getLastWebRequest().getUrl()); } + + /** + * @throws Exception if the test fails + */ + @Test + @Alerts({"5", "3", "[object HTMLSelectElement]", "[object HTMLTableElement]", "[object HTMLScriptElement]"}) + public void selectInsideEmptyTable() throws Exception { + final String html = "
\n" + + "