chromium/third_party/blink/web_tests/http/tests/storage/partitioned-storage/resources/clear-site-data-same-site-window.html

<!doctype html>
<head>
<title>Test Clear-Site-Data and partitioned storage</title>
<script src="/resources/testharness.js"></script>
<script src="/storage/resources/testharness-helpers.js"></script>
</head>
<body>
<script>

// We verify that calling Clear-Site-Data in another partition did
// not delete this partition's local storage.
test(() => {
  assert_equals(window.location.hostname, ORIGINAL_HOST);

  const iframe = document.createElement("iframe");
  const url = new URL(
      "/storage/partitioned-storage/resources/" +
          "clear-site-data-cross-site-frame.html?step=2",
      `https://${TEST_HOST}:${window.location.port}`);
  iframe.src = String(url);
  document.body.appendChild(iframe);
  fetch_tests_from_window(iframe.contentWindow);
}, "Opened page from first partition");

</script>
</body>