OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <head> |
| 3 <style>.id1 { background-color: red }</style> |
| 4 <link rel="stylesheet" |
| 5 crossorigin="anonymous" |
| 6 integrity="ni:///sha256;fy1lC6jbv7rOG6Flb00n5PYLggqe25IcE6QlZf8KtwI=" |
| 7 href="http://localhost:8000/security/resources/cors-style.php"></link> |
| 8 </head> |
| 9 <body> |
| 10 <script src="/js-test-resources/js-test.js"></script> |
| 11 <script> |
| 12 window.jsTestIsAsync = true; |
| 13 description("The test passes if the style loads and modifies the div to
be yellow without any console error."); |
| 14 |
| 15 window.onload = function () { |
| 16 var ele = document.getElementById('id1'); |
| 17 window.divBackground = window.getComputedStyle(ele, null).getPropert
yValue('background-color'); |
| 18 shouldBeEqualToString("divBackground", "rgb(255, 255, 0)"); |
| 19 finishJSTest(); |
| 20 }; |
| 21 </script> |
| 22 <div id="id1" class="id1"></div> |
| 23 </body> |
| 24 </html> |
OLD | NEW |