summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/semantics/scripting-1/the-script-element/import-attributes/empty-attributes-clause.html
blob: 0a8868b2f4ed1484f567f2dc983cda650d198f8d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<!DOCTYPE html>
<title>Handling of empty import attributes clause</title>

<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
    window.log = [];

    window.addEventListener("error", ev => log.push(ev.error));

    const test_load = async_test(
        "Test that no error occurs when an empty import attributes clause is provided.");
    window.addEventListener("load", test_load.step_func_done(ev => {
      assert_array_equals(window.log, ["hello", "empty-attributes-clause"]);
    }));

    function unreachable() { log.push("unexpected"); }
</script>
<script type="module" src="./empty-attributes-clause.js" onerror="unreachable()"></script>