Skip to content

Make it trivial to have a test run in window and worker scopes #2558

@Ms2ger

Description

@Ms2ger

Right now, the most straightforward way requires three files:

function test_withCredentials(worker) {
  test(function() {
    ...
  })
<!doctype html>
<meta charset=utf-8>
<title>XMLHttpRequest#withCredentials</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src=XMLHttpRequest-withCredentials.js></script>
<div id="log"></div>
<script>
test_withCredentials(false)
</script>
importScripts("/resources/testharness.js")
importScripts("XMLHttpRequest-withCredentials.js")
test_withCredentials(true);
done()

Since the latter two files are entirely boilerplate, we should be able to do it with just one file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions