summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/browsers/browsing-the-web/navigating-across-documents/source/navigate-child-function-parent.html
blob: bd2d9dfdb1e58b72b258047793be1bc4f07a3cf4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
<!doctype html>
<meta charset=utf-8>
<title>Set location from a parent</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<div id=log></div>
<iframe></iframe>
<script>
  onload = function() {
    var fr = document.querySelector("iframe")
    fr.contentWindow.location = "support/dummy.html"
    fr.onload = function() {
      assert_equals(fr.contentDocument.referrer, document.URL)
      done()
    }
  }
</script>