testing/web-platform/tests/content-security-policy/resource-hints/prefetch-allowed-by-default.html
author Emilio Cobos Álvarez <emilio@crisal.io>
Thu, 10 Jul 2025 09:08:54 +0000 (5 hours ago)
changeset 795952 1d422913e1cb1658224a2d269f8e4c9e80032d29
parent 654625 ca0b10cc05c2bac121ff50a7e6e86804dfca6e56
permissions -rw-r--r--
Bug 1976623 - Create drag popups eagerly for now. r=tnikkel,layout-reviewers Trivially restores pre-regression behavior, for now. Differential Revision: https://phabricator.services.mozilla.com/D256769
<!DOCTYPE html>
<html>

  <head>
    <script src='/resources/testharness.js'></script>
    <script src='/resources/testharnessreport.js'></script>
    <script src='/common/utils.js'></script>
    <script src='/content-security-policy/support/testharness-helper.js'></script>
    <script src='/content-security-policy/support/prefetch-helper.js'></script>

    <meta http-equiv="Content-Security-Policy" content="default-src 'self' 'unsafe-inline'">
    <script>
      promise_test(async t => {
        assert_true(await try_to_prefetch("/common/dummy.xml", t));
      }, 'Prefetch should succeed when allowed by default-src');
    </script>
  </head>

  <body>
  </body>

</html>