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

Side by Side Diff: third_party/WebKit/LayoutTests/loader/image-loader-base.html

Issue 2105283002: <image>'s src URL is resolved incorrectly when <base> element dynamically added (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: <image>'s src URL is resolved incorrectly when <base> element dynamically added. Created 4 years, 5 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
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <title>base element test </title>
5 <script src="../resources/testharness.js"></script>
6 <script src="../resources/testharnessreport.js"></script>
7 </head>
8 <body>
9 Test for bugs.chromium.org #569760: <br/>
10 <img id="img1" ><br/>
11 <script>
12 var test = async_test('image loading should be loaded successfully regardless of base element');
13
14 test.step(function () {
15 var elm = document.getElementById('img1');
16 elm.src = 'resources/image1.png';
Yoav Weiss 2016/07/19 06:15:17 shouldn't that say "image1.png"?
Yoav Weiss 2016/07/19 09:15:29 OK, I somehow thought the issue is the inverse (pr
17 elm.onerror = test.step_func(function () {
18 assert_unreached(" onerror() of image.");
Yoav Weiss 2016/07/19 09:15:29 spurious " " at beginning of sentence
kyounga.ra 2016/07/19 23:55:37 Done.
19 test.done();
20 });
21 elm.onload = test.step_func(function () {
22 assert_true(true, " Loaded successfully.");
Yoav Weiss 2016/07/19 09:15:29 spurious " " at beginning of sentence
kyounga.ra 2016/07/19 23:55:37 Done.
23 test.done();
24 });
25
26 var base = document.createElement("base");
27 base.setAttribute("href", "resources/");
28 document.head.appendChild(base);
29 });
30 </script>
31 </body>
32 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698