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

Unified Diff: LayoutTests/editing/style/apply-style-crash2.html

Issue 177093016: Fix crash in ApplyStyleCommand::applyRelativeFontStyleChange() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/editing/style/apply-style-crash2.html
diff --git a/LayoutTests/editing/style/apply-style-crash2.html b/LayoutTests/editing/style/apply-style-crash2.html
new file mode 100644
index 0000000000000000000000000000000000000000..0d3d3b5cf9866222e3a5430a370170bda7bdf846
--- /dev/null
+++ b/LayoutTests/editing/style/apply-style-crash2.html
@@ -0,0 +1,51 @@
+<!DOCTYPE html>
+<html>
+<script>
+if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+}
+
+onload = function() {
+var tests = [
+ "el0=document.createElement('input');",
leviw_travelin_and_unemployed 2014/02/25 18:45:36 This could be further minimized. Can you spend som
Inactive 2014/02/25 20:38:55 Done. Please let me know if the test is good enoug
+ "el1=document.createElement('canvas');",
+ "el2=document.createElement('select');",
+ "el3=document.createElement('li'); if(!el1.parentNode) { document.body.appendChild(el1) }; el1.parentNode.insertBefore(el3, el1); ",
+ "el4=document.createElement('thead'); el3.appendChild(el4); ",
+ "el5=document.createElement('video'); el4.parentNode.insertBefore(el5, el4); ",
+ "el6=document.createElement('canvas');",
+ "el7=document.createElement('input'); ",
+ "el8=document.createElement('form'); el4.appendChild(el8); ",
+ "el9=document.createElement('input'); ",
+ "el11=document.createElement('script'); document.body.appendChild(el11);",
+ "el12=document.createElement('ruby'); el0.appendChild(el12); ",
+ "document.designMode='on'; window.getSelection().setBaseAndExtent(el8, 2); document.designMode='off'",
+ "el13=document.createElement('textarea'); el12.parentNode.replaceChild(el13, el12);",
+ "el14=document.createElement('header'); ",
+ "el15=document.createElement('rp');",
+ "el18=document.createElement('input'); el4.parentNode.insertBefore(el18, el4); ",
+ "document.implementation.createDocument('' ,'' ,null).adoptNode(el15)",
+ "document.designMode='on'; window.getSelection().setBaseAndExtent(el6, 2, el11, 4); document.designMode='off'",
+ "window.getSelection().modify('extend', 'backward', 'character')",
+ "try { el3.innerHTML=el14.valueAsDate; } catch(e){}",
+ "document.designMode='on'; window.getSelection().setBaseAndExtent(el13, 2, el15, 1); document.execCommand('FontSizeDelta', false, '-1px'); document.designMode='off'",
+];
+
+function nextTest() {
+ for (var i = 0; i < 15; i++) {
+ var test = tests.shift();
+ if (!test) {
+ if (window.testRunner)
+ testRunner.notifyDone()
+ return;
+ }
+ eval(test);
+ };
+ setTimeout(nextTest, 0);
+}
+
+setTimeout(nextTest, 0)
+}
+</script>
+</html>
« no previous file with comments | « no previous file | LayoutTests/editing/style/apply-style-crash2-expected.txt » ('j') | Source/core/editing/ApplyStyleCommand.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698