OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <script src="../../../resources/js-test.js"></script> |
| 3 <script> |
| 4 description("This tests the handling of the link.crossOrigin attribute"); |
| 5 var link = document.createElement("link"); |
| 6 shouldBeTrue("'crossOrigin' in link"); |
| 7 shouldBeEqualToString("link.crossOrigin", ""); |
| 8 shouldBeEqualToString("link.setAttribute('crossorigin', ''); link.crossOrigin",
"anonymous"); |
| 9 shouldBeEqualToString("link.removeAttribute('crossorigin'); link.crossOrigin", "
"); |
| 10 shouldBeEqualToString("link.setAttribute('crossorigin', 'foo'); link.crossOrigin
", "anonymous"); |
| 11 shouldBeEqualToString("link.setAttribute('crossorigin', 'ANONYMOUS'); link.cross
Origin", "anonymous"); |
| 12 shouldBeEqualToString("link.setAttribute('crossorigin', 'use-credentials'); link
.crossOrigin", "use-credentials"); |
| 13 shouldBeEqualToString("link.crossOrigin = ''; link.getAttribute('crossorigin')",
""); |
| 14 shouldBeEqualToString("link.crossOrigin = 'foo'; link.getAttribute('crossorigin'
)", "foo"); |
| 15 shouldBeEqualToString("link.crossOrigin = null; link.getAttribute('crossorigin')
", "null"); |
| 16 shouldBeEqualToString("link.crossOrigin = 'ANONYMOUS'; link.getAttribute('crosso
rigin')", "ANONYMOUS"); |
| 17 shouldBeEqualToString("link.crossOrigin = 'use-credentials'; link.getAttribute('
crossorigin')", "use-credentials"); |
| 18 </script> |
OLD | NEW |