OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <title>This tests onerror event is fired if we change image src to a url blocked
by content-security-policy.</title> |
| 3 <meta http-equiv="Content-Security-Policy" content="img-src 'self'"> |
| 4 <script src="../../../resources/testharness.js"></script> |
| 5 <script src="../../../resources/testharnessreport.js"></script> |
| 6 <img src="../resources/square.png"></img> |
| 7 <script> |
| 8 //TODO(siva.gunturi): Verify that the initial reference loads ok. |
| 9 async_test(function(t) { |
| 10 var img = document.querySelector("img"); |
| 11 img.onerror = t.step_func_done(); |
| 12 img.src = "http://127.0.0.1:8080/resources/square.png"; |
| 13 }); |
| 14 </script> |
OLD | NEW |