<!DOCTYPE html>
<title>DedicatedWorker: ES modules for data URL workers</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>

const import_from_data_url_worker_test = (importType, isDataURL, expectation) => {
  promise_test(async () => {
    const importURL = new URL(`resources/${importType}-import-` +
        `${isDataURL ? 'data-url' : 'script'}-block-cross-origin.js`,
        location.href) + '?pipe=header(Access-Control-Allow-Origin, 