Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!doctype html> | |
| 2 <meta charset=utf-8> | |
| 3 <meta http-equiv="Content-Security-Policy" content="font-src 'none'"> | |
| 4 <head> | |
| 5 <title>csp font-src: whitelisted</title> | |
| 6 <script src='/resources/testharness.js'></script> | |
| 7 <script src='/resources/testharnessreport.js'></script> | |
| 8 </head> | |
| 9 <body> | |
| 10 <div id="log"/> | |
| 11 <script> | |
| 12 async_test(function(t) { | |
| 13 var link = document.createElement('link'); | |
| 14 link.rel="stylesheet" | |
| 15 link.type="text/css"; | |
| 16 link.href="/content-security-policy/support/fonts.css"; | |
| 17 link.onload = t.unreached_func("Should not have loaded the font."); | |
| 18 link.onload = t.step_func_done(); | |
|
Mike West
2017/03/27 11:47:03
`onload` + `onload` = this test is a noop.
| |
| 19 document.getElementsByTagName('head')[0].appendChild(link); | |
| 20 }, "Test font does not load if it does not match font-src."); | |
| 21 </script> | |
| 22 </body> | |
| OLD | NEW |