| Index: third_party/WebKit/LayoutTests/imported/wpt/html/semantics/document-metadata/the-link-element/link-style-error-01.html
|
| diff --git a/third_party/WebKit/LayoutTests/imported/wpt/html/semantics/document-metadata/the-link-element/link-style-error-01.html b/third_party/WebKit/LayoutTests/imported/wpt/html/semantics/document-metadata/the-link-element/link-style-error-01.html
|
| index ce35e03d93f09d306ebcb0aae207a60905212fc1..04608460b83ebcea3cdba551ed1320ee357ac37d 100644
|
| --- a/third_party/WebKit/LayoutTests/imported/wpt/html/semantics/document-metadata/the-link-element/link-style-error-01.html
|
| +++ b/third_party/WebKit/LayoutTests/imported/wpt/html/semantics/document-metadata/the-link-element/link-style-error-01.html
|
| @@ -7,17 +7,32 @@
|
| <div id="log"></div>
|
| <div id="test">
|
| <script>
|
| -//var t404 = async_test("Should get an error event for a 404 error.")
|
| -//t404.step(function() {
|
| -// var elt = document.createElement("link");
|
| -// elt.onerror = t404.step_func(function() {
|
| -// assert_true(true, "Got error event for 404 error.")
|
| -// t404.done()
|
| -// })
|
| -// elt.rel = "stylesheet";
|
| -// elt.href = 404 error;
|
| -// document.getElementsByTagName("head")[0].appendChild(elt);
|
| -//})
|
| +var t404 = async_test("Should get an error event for a 404 error.")
|
| +t404.step(function() {
|
| + var elt = document.createElement("link");
|
| + elt.onerror = t404.step_func(function() {
|
| + assert_true(true, "Got error event for 404 error.")
|
| + t404.step_timeout(function() { t404.done() }, 0);
|
| + })
|
| + elt.onload = t404.unreached_func("load event should not be fired");
|
| + elt.rel = "stylesheet";
|
| + elt.href = "nonexistent_stylesheet.css";
|
| + document.getElementsByTagName("head")[0].appendChild(elt);
|
| +})
|
| +
|
| +var tUnsupported = async_test("Should get an error event for an unsupported URL.")
|
| +tUnsupported.step(function() {
|
| + var elt = document.createElement("link");
|
| + elt.onerror = tUnsupported.step_func(function() {
|
| + assert_true(true, "Got error event for unsupported URL.")
|
| + tUnsupported.step_timeout(function() { tUnsupported.done() }, 0);
|
| + })
|
| + elt.onload = tUnsupported.unreached_func("load event should not be fired");
|
| + elt.rel = "stylesheet";
|
| + elt.href = "nonexistent:stylesheet.css";
|
| + document.getElementsByTagName("head")[0].appendChild(elt);
|
| +})
|
| +
|
| var tText = async_test("Should get an error event for a text/plain response.")
|
| tText.step(function() {
|
| var elt = document.createElement("link");
|
|
|