Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: third_party/WebKit/LayoutTests/editing/execCommand/queryCommandState-03.html

Issue 1960553002: Do not ignore the text style properties when checking styles in EditingStyle. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: move the test case Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/queryCommandState-03-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <html>
yosin_UTC9 2016/05/09 03:43:50 Could you use w3c test harness? Here is an example
2 <body>
3 This tests queryCommandState.
4 <p>
5 <a href="https://bugs.chromium.org/p/chromium/issues/detail?id=584939">Bug 58493 9</a>
6 </p>
7 <div contenteditable="true">
8 <img src="../resources/abe.png">
9 </div>
10 <ul id="console"></ul>
11
12 <script type="text/javascript">
13
14 if (window.testRunner) {
15 testRunner.dumpAsText();
16 }
17
18 document.getSelection().removeAllRanges();
19 var range = document.createRange();
20 range.selectNode(document.querySelector('img'));
21 document.getSelection().addRange(range);
22
23 assert(!document.queryCommandState('bold'));
24 assert(!document.queryCommandState('italic'));
25 assert(!document.queryCommandState('underline'));
26 assert(!document.queryCommandState('strikethrough'));
27
28 function log(str) {
29 var li = document.createElement("li");
30 li.appendChild(document.createTextNode(str));
31 var console = document.getElementById("console");
32 console.appendChild(li);
33 }
34
35 function assert(bool) {
36 if (!bool)
37 log("Failure");
38 else
39 log("Success");
40 }
41 </script>
42
43 </body>
44 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/editing/execCommand/queryCommandState-03-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698