Commit 2935b111 authored by yosin's avatar yosin Committed by Commit bot

Convert editing/deleting/merge-paragraph-into-pre.html to use w3c test harness

This patch converts "editing/deleting/merge-paragraph-into-pre.html" to use w3c
test harness to simplify test script for improving readability.

BUG=n/a
TEST=n/a; no behavior changes

Review-Url: https://codereview.chromium.org/2289093002
Cr-Commit-Position: refs/heads/master@{#415552}
parent e4a4c8ba
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
This tests deleting line break after pre.
WebKit should not cancel styles added by pre by those of document's default style.
| "
"
| <pre>
| "hello<#selection-caret>world"
<!DOCTYPE html> <!doctype html>
<html> <script src="../../resources/testharness.js"></script>
<body> <script src="../../resources/testharnessreport.js"></script>
<p id="description">This tests deleting line break after pre. <script src="../assert_selection.js"></script>
WebKit should not cancel styles added by pre by those of document's default style.</p>
<div id="test" contenteditable>
<pre>hello</pre>
world
</div>
</div>
<script src="../editing.js"></script>
<script src="../../resources/dump-as-markup.js"></script>
<script> <script>
test(() => assert_selection(
function editingTest() { '<div contenteditable><pre>hello</pre>\n|world</div>',
moveSelectionForwardByLineCommand(); 'delete',
deleteCommand(); // We should not cancel styles added BY PRE by those of document's
// default style.
Markup.description(document.getElementById('description').textContent); '<div contenteditable><pre>hello|world</pre></div>'),
Markup.dump('test'); 'Delete line break after PRE');
}
runEditingTest();
</script> </script>
</body>
</html>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment