diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /dom/xbl/test/file_bug379959_cross.html | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'dom/xbl/test/file_bug379959_cross.html')
-rw-r--r-- | dom/xbl/test/file_bug379959_cross.html | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/dom/xbl/test/file_bug379959_cross.html b/dom/xbl/test/file_bug379959_cross.html new file mode 100644 index 000000000..80e2be97d --- /dev/null +++ b/dom/xbl/test/file_bug379959_cross.html @@ -0,0 +1,32 @@ +<!DOCTYPE HTML> +<html> +<head> +<style> +#div1 { + color: green; + -moz-binding: url(file_bug379959_xbl.xml#xbltest); +} +#div2 { + color: green; + -moz-binding: url(http://example.com/tests/dom/xbl/test/file_bug379959_xbl.xml#xbltest); +} +</style> +<body> +<div id="div1"></div> +<div id="div2"></div> +<script> +onload = function() { + // same origin should be allowed + var nodes1 = SpecialPowers.wrap(document).getAnonymousNodes(document.getElementById('div1')); + parent.postMessage({test: "sameOriginIsAllowed", + result: nodes1 ? nodes1.length : 0, + senderURL: "http://mochi.test:8888"}, "*"); + + // cross origin should be blocked + var nodes2 = SpecialPowers.wrap(document).getAnonymousNodes(document.getElementById('div2')); + parent.postMessage({test: "crossOriginIsBlocked", + result: nodes2 ? nodes2.length : 0, + senderURL: "http://mochi.test:8888"}, "*"); +} +</script> +</html> |