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

Unified Diff: LayoutTests/fast/html/marquee-clone-crash.html

Issue 809343002: ScopedStyleResolver should be cleared when ShadowRoot is removed from document. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Imported test from https://codereview.chromium.org/808333002/ Created 6 years 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
« no previous file with comments | « no previous file | LayoutTests/fast/html/marquee-clone-crash-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/html/marquee-clone-crash.html
diff --git a/LayoutTests/fast/html/marquee-clone-crash.html b/LayoutTests/fast/html/marquee-clone-crash.html
new file mode 100644
index 0000000000000000000000000000000000000000..91e322ae16c15c2e0dd4fde71c41a2603ccec2a0
--- /dev/null
+++ b/LayoutTests/fast/html/marquee-clone-crash.html
@@ -0,0 +1,61 @@
+<!DOCTYPE html>
+<script>
+var ex = false;
+var doc;
+var count = 0;
+
+if (window.testRunner)
+ testRunner.waitUntilDone();
+
+function start() {
+ if (location.hash == "") {
+ location.hash = "#0";
+ } else {
+ count = parseInt(location.hash.substring(1));
+ if (count >= 5) {
+ document.write('PASS');
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.notifyDone();
+ }
+ return;
+ }
+ }
+
+ doc = document.documentElement;
+ mq1 = document.createElement('marquee');
+ var iframe = document.createElement('iframe');
+ iframe.src = "nonexistent";
+
+ doc.appendChild(iframe);
+ mq2 = mq1.cloneNode(false);
+
+ iframe.onload = iframe_onload;
+ setTimeout('start_pause1()', 100);
+}
+
+function start_pause1() {
+ document.removeChild(doc);
+ document.appendChild(doc);
+ setTimeout('start_pause2()', 100);
+}
+
+function start_pause2() {
+ document.removeChild(doc);
+ gc();
+ document.appendChild(doc);
+ location.hash = '#' + ++count;
+ location.reload();
+}
+
+function iframe_onload() {
+ if (ex)
+ return;
+ ex = true;
+
+ var iframe = document.createElement('iframe');
+ iframe.src='resources/marquee-crash.svg';
+ doc.appendChild(iframe);
+}
+</script>
+<body onload="start()"></body>
« no previous file with comments | « no previous file | LayoutTests/fast/html/marquee-clone-crash-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698