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

Side by Side Diff: LayoutTests/fast/html/imports/import-readd-nested.html

Issue 331763002: HTML Imports: styles in removed imports should be applied when it comes back (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script src="../../../resources/testharness.js"></script>
5 <script src="../../../resources/testharnessreport.js"></script>
6 <link rel=import href="./resources/style-red-parent.html">
7 </head>
8 <body>
9 <h1 class="target">Should be red</h1>
10 <script>
11 var t = async_test('Styles in grandchild are re-applied after removed imports ar e re-added');
12 window.onload = function() {
13 t.step(function() {
14 var importLink = document.querySelector('link');
15 document.head.removeChild(importLink);
16 document.head.appendChild(importLink);
17 assert_equals(window.getComputedStyle(document.querySelector('.target')) .color, 'rgb(255, 0, 0)');
18 Array.prototype.forEach.call(document.querySelectorAll("h1"), function(e ) { e.style.display = "none"; });
19 t.done();
20 });
21 }
22 </script>
23 </body>
24 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698