chromium/third_party/blink/web_tests/http/tests/security/base-url-data.html

<!DOCTYPE html>
<head>
  <script src="/resources/testharness.js"></script>
  <script src="/resources/testharnessreport.js"></script>
  <script src="/common/get-host-info.sub.js"></script>

  <base href="data:/,This is a data URL.">
</head>
<body>
  <script>
    async_test(t => {
      var base = document.querySelector('base');
      var img = new Image();
      img.onload = t.step_func_done(_ => {
        assert_equals(img.naturalWidth, 76, "Image loaded correctly.");
        assert_equals(img.src, "http://127.0.0.1:8000/security/resources/abe.png");
        // Fails unless kStandardCompliantNonSpecialSchemeURLParsing is enabled.
        // See https://crbug.com/40063064.
        assert_equals(base.href, 'data:/,This%20is%20a%20data%20URL.');
      });
      img.onerror = t.unreached_func("Image should have loaded.");

      img.src = "/security/resources/abe.png";
    }, "'data:' is an invalid base URL.");
  </script>
</body>