Bug 26365
| Summary: | /LayoutTests/editing/deleting/5390681.html doesn't test what it claims to test | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Ryosuke Niwa <rniwa> |
| Component: | Tools / Tests | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | jparent |
| Priority: | P4 | ||
| Version: | 528+ (Nightly build) | ||
| Hardware: | All | ||
| OS: | All | ||
Ryosuke Niwa
The expected result of /LayoutTests/editing/deleting/5390681.html seems to be incorrect. We shouldn't be inserting a placeholder. The dumpAsText version of this test is:
<p>This tests for a bug where expansion for smart delete would not consider editable boundaries. Only 'foo' should be deleted. You should see ' bar'. <b>There is a bug: while the non-editable space isn't deleted, deletion inserts a placeholder when it shouldn't.</b></p>
<div contenteditable="true" id="div">foo<span contenteditable="false"> bar</span></div>
<p id="console"></p>
<script>
if (window.layoutTestController)
window.layoutTestController.dumpAsText();
function log(message) {
var console = document.getElementById("console");
var text = document.createTextNode(message);
console.appendChild(text);
}
var div = document.getElementById("div");
var sel = window.getSelection();
sel.setPosition(div, 0);
sel.modify("extend", "forward", "word");
document.execCommand("Delete");
log(document.getElementById('div').innerHTML);
</script>
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Ryosuke Niwa
The test has since been converted to a dump-as-markup test and http://trac.webkit.org/changeset/95003 renamed the test.