chromium/third_party/blink/web_tests/http/tests/cache/subresource-revalidation-referrer.html

<!DOCTYPE HTML>
<script src="/js-test-resources/js-test.js"></script>
<script src="resources/referrer-echo.php" type="text/javascript"></script>
<script>
description("Check that Referrer: for validation requests are correctly set.");
window.jsTestIsAsync = true;

// The above script adds the 'referrer' global.
shouldBeTrue('referrer.indexOf("subresource-revalidation-referrer.html") >= 0');

var first = true;
function iframeLoaded(ref) {
    if (first) {
        // Navigating the iframe-embedded anchor will use the iframe's
        // URL as referrer.
        first = false;
        window.frames[0].document.getElementsByTagName("a")[0].click();
    } else {
        referrer = ref;
        shouldBeTrue('referrer.indexOf("subresource-revalidation-referrer-iframe.html") >= 0');
        finishJSTest();
    }
}
</script>
<iframe src="resources/subresource-revalidation-referrer-iframe.html"></iframe>