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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/innerHTML/innerHTML-uri-resolution.html

Issue 1363233003: Make sure <url>s are being serialized according to spec (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix interpolation tests Created 5 years, 2 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../../resources/js-test.js"></script> 4 <script src="../../resources/js-test.js"></script>
5 </head> 5 </head>
6 <body> 6 <body>
7 <div id="container"></div> 7 <div id="container"></div>
8 <script> 8 <script>
9 description('Checks that URIs used in styles that are set via innerHTML are re solved against the current document\'s base URI.'); 9 description('Checks that URIs used in styles that are set via innerHTML are re solved against the current document\'s base URI.');
10 10
11 document.getElementById('container').innerHTML = 11 document.getElementById('container').innerHTML =
12 '<span id="test-span" style="background-image: url(image.png)"></span>'; 12 '<span id="test-span" style="background-image: url(image.png)"></span>';
13 13
14 var currentUri = document.location.href; 14 var currentUri = document.location.href;
15 var currentPath = currentUri.substring(0, currentUri.lastIndexOf('/')); 15 var currentPath = currentUri.substring(0, currentUri.lastIndexOf('/'));
16 var cssUriWasResolvedAgainstDocumentUri = document.getElementById("test-span") .style.backgroundImage == 'url(image.png)'; 16 var cssUriWasResolvedAgainstDocumentUri = document.getElementById("test-span") .style.backgroundImage == 'url("image.png")';
17 17
18 // Can't log the actual path since it's different depending on where the test is run. 18 // Can't log the actual path since it's different depending on where the test is run.
19 shouldBeTrue('cssUriWasResolvedAgainstDocumentUri'); 19 shouldBeTrue('cssUriWasResolvedAgainstDocumentUri');
20 </script> 20 </script>
21 </body> 21 </body>
22 </html> 22 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698