[Webkit-unassigned] [Bug 179605] New: [GTK] Test editing/execCommand/underline-selection-containing-image.html fails since added in r224649
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Nov 13 01:48:07 PST 2017
https://bugs.webkit.org/show_bug.cgi?id=179605
Bug ID: 179605
Summary: [GTK] Test
editing/execCommand/underline-selection-containing-ima
ge.html fails since added in r224649
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Keywords: Gtk, LayoutTestFailure
Severity: Normal
Priority: P2
Component: WebKit Gtk
Assignee: webkit-unassigned at lists.webkit.org
Reporter: cgarcia at igalia.com
CC: bugs-noreply at webkitgtk.org, rniwa at webkit.org,
wenson_hsieh at apple.com
This is failing also in windows, and I'm getting similar results with chromium, so it seems the test depends on mac specific behavior. This is what the test does:
document.body.focus();
document.execCommand("InsertHTML", true, "<img></img>");
document.execCommand("SelectAll");
document.execCommand("Underline");
document.execCommand("InsertText", true, "foo");
document.body.textContent = `The underlined text should be 'foo': '${document.querySelector("U").textContent}'`;
The difference is when executing Underline command. In mac at that point an empty <u></u> is added, so next command is adding foo inside the <u></u>. But that's not happening in GTK+, Underline command is not modifying the tree (I guess because it's applied to the selection that is considered empty), so next command just inserts the text replacing the selection (img). The result is an exception because querySelector returns null.
CONSOLE MESSAGE: line 12: TypeError: null is not an object (evaluating 'document.querySelector("U").textContent')
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20171113/e8a396bc/attachment.html>
More information about the webkit-unassigned
mailing list