summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/service-workers/service-worker/resources/secure-context/window.html
blob: 071a507cb33e95e5b9cfc9a0bbccadab0983efee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<body>
<script src="/common/get-host-info.sub.js"></script>
<script src="../test-helpers.sub.js"></script>
<script>
const HTTPS_PREFIX = get_host_info().HTTPS_ORIGIN + base_path();

window.onmessage = event => {
    window.location = HTTPS_PREFIX + 'report?result=' + event.data;
};

const frame = document.createElement('iframe');
frame.src = HTTPS_PREFIX + 'sender.html';
document.body.appendChild(frame);
</script>
</body>