Skip to content

Commit c8ce1b1

Browse files
authored
Merge fd1c9c8 into 432dbab
2 parents 432dbab + fd1c9c8 commit c8ce1b1

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
async_test(t => {
2+
const frame = document.createElement("iframe"),
3+
asciiOrigin = location.protocol + "//{{domains[天気の良い日]}}:" + location.port,
4+
path = new URL("resources/post-your-origin.html", location).pathname;
5+
frame.src = asciiOrigin + path;
6+
self.onmessage = t.step_func_done(e => {
7+
assert_equals(e.data.origin, asciiOrigin);
8+
});
9+
document.body.appendChild(frame);
10+
t.add_cleanup(() => frame.remove());
11+
}, "Test that location.origin returns ASCII");
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<script>
2+
parent.postMessage({origin: location.origin}, "*");
3+
</script>

0 commit comments

Comments
 (0)