зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1509204 [wpt PR 14172] - [streams] Refactor to multi-global test format, a=testonly
Automatic update from web-platform-tests[streams] Refactor to multi-global test format (#14172) * Rename streams tests to .any.js * Use metadata to import resources in streams tests * Run streams tests in all scopes * Delete old test wrappers * Delete old test wrapper generator * Replace setTimeout with step_timeout * Use t.step_timeout in tests * Remove obsolete done calls -- wpt-commits: a89730a0f3638d709ccc42064c8f8eb8935b04f7 wpt-pr: 14172
This commit is contained in:
Родитель
231548a109
Коммит
76a8611523
|
@ -206,13 +206,6 @@ SET TIMEOUT: shadow-dom/Document-prototype-currentScript.html
|
|||
SET TIMEOUT: shadow-dom/scroll-to-the-fragment-in-shadow-tree.html
|
||||
SET TIMEOUT: shadow-dom/slotchange-event.html
|
||||
SET TIMEOUT: shadow-dom/untriaged/html-elements-in-shadow-trees/html-forms/test-003.html
|
||||
SET TIMEOUT: streams/piping/close-propagation-forward.js
|
||||
SET TIMEOUT: streams/piping/error-propagation-backward.js
|
||||
SET TIMEOUT: streams/piping/error-propagation-forward.js
|
||||
SET TIMEOUT: streams/piping/general.js
|
||||
SET TIMEOUT: streams/readable-streams/cancel.js
|
||||
SET TIMEOUT: streams/resources/rs-utils.js
|
||||
SET TIMEOUT: streams/writable-streams/byte-length-queuing-strategy.js
|
||||
SET TIMEOUT: trusted-types/block-string-assignment-to-DOMWindowTimers-setTimeout-setInterval.tentative.html
|
||||
SET TIMEOUT: trusted-types/DOMWindowTimers-setTimeout-setInterval.tentative.html
|
||||
SET TIMEOUT: user-timing/*
|
||||
|
|
|
@ -1,14 +1,3 @@
|
|||
# Streams Tests
|
||||
|
||||
The work on the streams tests is closely tracked by the specification authors, who maintain a reference implementation intended to match the spec line-by-line while passing all of these tests. See [the whatwg/streams repository for details](https://github.com/whatwg/streams/tree/master/reference-implementation). Some tests may be in that repository while the spec sections they test are still undergoing heavy churn.
|
||||
|
||||
## Generating wrapper files
|
||||
|
||||
Because the streams feature is supposed to work in all global contexts, each test is written as a `.js` file, and then four `.html` files are generated around it. So for example, for `count-queueing-strategy.js`, we have the wrapper files:
|
||||
|
||||
- `count-queueing-strategy.https.html`
|
||||
- `count-queueing-strategy.dedicatedworker.html`
|
||||
- `count-queueing-strategy-sharedworker.html`
|
||||
- `count-queueing-strategy-serviceworker.html`
|
||||
|
||||
These are generated automatically by the Node.js script in `generate-test-wrappers.js`. See it for details, and please remember to use it whenever adding new tests.
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
// META: global=worker
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
test(() => {
|
||||
|
||||
new ByteLengthQueuingStrategy({ highWaterMark: 4 });
|
||||
|
@ -110,5 +107,3 @@ test(() => {
|
|||
'ByteLengthQueuingStrategy.name must be "ByteLengthQueuingStrategy"');
|
||||
|
||||
}, 'ByteLengthQueuingStrategy.name is correct');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>byte-length-queuing-strategy.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('byte-length-queuing-strategy.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>byte-length-queuing-strategy.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
|
||||
|
||||
<script src="byte-length-queuing-strategy.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>byte-length-queuing-strategy.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('byte-length-queuing-strategy.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>byte-length-queuing-strategy.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('byte-length-queuing-strategy.js'));
|
||||
</script>
|
|
@ -1,9 +1,6 @@
|
|||
// META: global=worker
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
test(() => {
|
||||
|
||||
new CountQueuingStrategy({ highWaterMark: 4 });
|
||||
|
@ -109,5 +106,3 @@ test(() => {
|
|||
'CountQueuingStrategy.name must be "CountQueuingStrategy"');
|
||||
|
||||
}, 'CountQueuingStrategy.name is correct');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>count-queuing-strategy.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('count-queuing-strategy.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>count-queuing-strategy.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
|
||||
|
||||
<script src="count-queuing-strategy.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>count-queuing-strategy.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('count-queuing-strategy.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>count-queuing-strategy.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('count-queuing-strategy.js'));
|
||||
</script>
|
|
@ -1,99 +0,0 @@
|
|||
"use strict";
|
||||
// Usage: `node generate-test-wrappers.js js-filename1.js [js-filename2.js ...]` will generate:
|
||||
// - js-filename1.html
|
||||
// - js-filename1.sharedworker.html
|
||||
// - js-filename1.dedicatedworker.html
|
||||
// - js-filename1.serviceworker.https.html
|
||||
// (for each passed filename)
|
||||
//
|
||||
// It will turn any importScripts inside the .js file into <script>s in the browser context wrapper.
|
||||
//
|
||||
// This could become obsolete if https://github.com/web-platform-tests/wpt/issues/4210 gets fixed,
|
||||
// allowing .any.js to work with all four contexts.
|
||||
|
||||
const fs = require("fs");
|
||||
const path = require("path");
|
||||
|
||||
for (const arg of process.argv.slice(2)) {
|
||||
generateWrapper(arg);
|
||||
}
|
||||
|
||||
function generateWrapper(jsFilename) {
|
||||
const importedScriptFilenames = findImportedScriptFilenames(jsFilename);
|
||||
const importedScriptTags = importedScriptFilenames
|
||||
.map(filename => `<script src="${filename}"></script>`)
|
||||
.join('\n');
|
||||
|
||||
const basename = path.basename(jsFilename);
|
||||
const noExtension = path.basename(jsFilename, '.js');
|
||||
|
||||
const outputs = {
|
||||
'.html': `<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>${basename} browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
${importedScriptTags}
|
||||
|
||||
<script src="${basename}"></script>
|
||||
`,
|
||||
'.dedicatedworker.html': `<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>${basename} dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('${basename}'));
|
||||
</script>
|
||||
`,
|
||||
'.sharedworker.html': `<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>${basename} shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('${basename}'));
|
||||
</script>
|
||||
`,
|
||||
'.serviceworker.https.html': `<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>${basename} service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('${basename}', 'Service worker test setup');
|
||||
</script>
|
||||
`
|
||||
};
|
||||
|
||||
for (const [key, value] of Object.entries(outputs)) {
|
||||
const destFilename = path.resolve(path.dirname(jsFilename), `${noExtension}${key}`);
|
||||
fs.writeFileSync(destFilename, value, { encoding: 'utf-8' });
|
||||
}
|
||||
}
|
||||
|
||||
function findImportedScriptFilenames(inputFilename) {
|
||||
const scriptContents = fs.readFileSync(inputFilename, { encoding: 'utf-8' });
|
||||
|
||||
const regExp = /self\.importScripts\('([^']+)'\);/g;
|
||||
|
||||
let result = [];
|
||||
let match;
|
||||
while (match = regExp.exec(scriptContents)) {
|
||||
result.push(match[1]);
|
||||
}
|
||||
|
||||
return result.filter(x => x !== '/resources/testharness.js');
|
||||
}
|
|
@ -1,14 +1,11 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/recording-streams.js
|
||||
// META: script=../resources/test-utils.js
|
||||
'use strict';
|
||||
|
||||
// Tests for the use of pipeTo with AbortSignal.
|
||||
// There is some extra complexity to avoid timeouts in environments where abort is not implemented.
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1');
|
||||
error1.name = 'error1';
|
||||
const error2 = new Error('error2');
|
||||
|
@ -361,5 +358,3 @@ promise_test(t => {
|
|||
assert_array_equals(rs.events, ['pull'], 'cancel should not have been called');
|
||||
});
|
||||
}, 'abort should do nothing after the writable is errored');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>abort.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('abort.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>abort.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
|
||||
<script src="abort.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>abort.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('abort.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>abort.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('abort.js'));
|
||||
</script>
|
|
@ -1,10 +1,7 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -154,5 +151,3 @@ promise_test(t => {
|
|||
|
||||
}, 'Closing must be propagated backward: starts closed; preventCancel = true, preventAbort = true, preventClose ' +
|
||||
'= true');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-backward.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('close-propagation-backward.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-backward.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="close-propagation-backward.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-backward.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('close-propagation-backward.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-backward.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('close-propagation-backward.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -158,7 +155,7 @@ promise_test(() => {
|
|||
|
||||
}, 'Closing must be propagated forward: starts closed; preventClose = true, preventAbort = true, preventCancel = true');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -166,7 +163,7 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws);
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(value => {
|
||||
assert_equals(value, undefined, 'the promise must fulfill with undefined');
|
||||
|
@ -195,7 +192,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -209,7 +206,7 @@ promise_test(t => {
|
|||
|
||||
}, 'Closing must be propagated forward: becomes closed asynchronously; preventClose omitted; rejected close promise');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -217,7 +214,7 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws, { preventClose: true });
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(value => {
|
||||
assert_equals(value, undefined, 'the promise must fulfill with undefined');
|
||||
|
@ -231,7 +228,7 @@ promise_test(() => {
|
|||
|
||||
}, 'Closing must be propagated forward: becomes closed asynchronously; preventClose = true');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -239,7 +236,7 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws);
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(value => {
|
||||
assert_equals(value, undefined, 'the promise must fulfill with undefined');
|
||||
|
@ -269,7 +266,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -284,7 +281,7 @@ promise_test(t => {
|
|||
}, 'Closing must be propagated forward: becomes closed asynchronously; dest never desires chunks; ' +
|
||||
'preventClose omitted; rejected close promise');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -292,7 +289,7 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws, { preventClose: true });
|
||||
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
|
||||
return pipePromise.then(value => {
|
||||
assert_equals(value, undefined, 'the promise must fulfill with undefined');
|
||||
|
@ -307,7 +304,7 @@ promise_test(() => {
|
|||
}, 'Closing must be propagated forward: becomes closed asynchronously; dest never desires chunks; ' +
|
||||
'preventClose = true');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -315,9 +312,9 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws);
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(value => {
|
||||
|
@ -347,9 +344,9 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -364,7 +361,7 @@ promise_test(t => {
|
|||
|
||||
}, 'Closing must be propagated forward: becomes closed after one chunk; preventClose omitted; rejected close promise');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
const rs = recordingReadableStream();
|
||||
|
||||
|
@ -372,9 +369,9 @@ promise_test(() => {
|
|||
|
||||
const pipePromise = rs.pipeTo(ws, { preventClose: true });
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.close());
|
||||
t.step_timeout(() => rs.controller.close());
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(value => {
|
||||
|
@ -590,5 +587,3 @@ promise_test(t => {
|
|||
]);
|
||||
});
|
||||
}, 'Closing must be propagated forward: erroring the writable while flushing pending writes should error pipeTo');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-forward.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('close-propagation-forward.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-forward.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="close-propagation-forward.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-forward.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('close-propagation-forward.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>close-propagation-forward.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('close-propagation-forward.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -373,7 +370,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, ['cancel', error1]);
|
||||
|
@ -394,7 +391,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the cancel error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, ['cancel', error1]);
|
||||
|
@ -412,7 +409,7 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventCancel: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -486,7 +483,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, ['cancel', error1]);
|
||||
|
@ -508,7 +505,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the cancel error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, ['cancel', error1]);
|
||||
|
@ -527,7 +524,7 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventCancel: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => ws.controller.error(error1), 10);
|
||||
t.step_timeout(() => ws.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -631,5 +628,3 @@ promise_test(t => {
|
|||
});
|
||||
|
||||
}, 'Errors must be propagated backward: erroring via the controller errors once pending write completes');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-backward.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('error-propagation-backward.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-backward.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="error-propagation-backward.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-backward.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('error-propagation-backward.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-backward.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('error-propagation-backward.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -143,7 +140,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -164,7 +161,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the abort error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -182,7 +179,7 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventAbort: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -199,7 +196,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -221,7 +218,7 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the abort error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -240,7 +237,7 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventAbort: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
assert_array_equals(rs.eventsWithoutPulls, []);
|
||||
|
@ -258,9 +255,9 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -282,9 +279,9 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the abort error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -303,9 +300,9 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventAbort: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -323,9 +320,9 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws), 'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -348,9 +345,9 @@ promise_test(t => {
|
|||
|
||||
const pipePromise = promise_rejects(t, error2, rs.pipeTo(ws), 'pipeTo must reject with the abort error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -370,9 +367,9 @@ promise_test(t => {
|
|||
const pipePromise = promise_rejects(t, error1, rs.pipeTo(ws, { preventAbort: true }),
|
||||
'pipeTo must reject with the same error');
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
rs.controller.enqueue('Hello');
|
||||
setTimeout(() => rs.controller.error(error1), 10);
|
||||
t.step_timeout(() => rs.controller.error(error1), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise.then(() => {
|
||||
|
@ -570,5 +567,3 @@ promise_test(t => {
|
|||
});
|
||||
|
||||
}, 'Errors must be propagated forward: shutdown must not occur until the final write completes; becomes errored after first write; preventAbort = true');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-forward.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('error-propagation-forward.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-forward.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="error-propagation-forward.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-forward.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('error-propagation-forward.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>error-propagation-forward.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('error-propagation-forward.js'));
|
||||
</script>
|
|
@ -1,12 +1,9 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/rs-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/rs-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -302,5 +299,3 @@ promise_test(() => {
|
|||
]);
|
||||
});
|
||||
}, 'Piping to a WritableStream that does not consume the writes fast enough exerts backpressure on the ReadableStream');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>flow-control.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('flow-control.js'));
|
||||
</script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>flow-control.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/rs-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="flow-control.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>flow-control.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('flow-control.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>flow-control.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('flow-control.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
test(() => {
|
||||
|
||||
const rs = new ReadableStream();
|
||||
|
@ -130,7 +127,7 @@ promise_test(() => {
|
|||
|
||||
}, 'Piping from a ReadableStream from which lots of chunks are synchronously readable');
|
||||
|
||||
promise_test(() => {
|
||||
promise_test(t => {
|
||||
|
||||
let controller;
|
||||
const rs = recordingReadableStream({
|
||||
|
@ -145,9 +142,9 @@ promise_test(() => {
|
|||
assert_array_equals(ws.events, ['write', 'Hello', 'close']);
|
||||
});
|
||||
|
||||
setTimeout(() => {
|
||||
t.step_timeout(() => {
|
||||
controller.enqueue('Hello');
|
||||
setTimeout(() => controller.close(), 10);
|
||||
t.step_timeout(() => controller.close(), 10);
|
||||
}, 10);
|
||||
|
||||
return pipePromise;
|
||||
|
@ -191,5 +188,3 @@ for (const preventCancel of [true, false]) {
|
|||
|
||||
}, `an undefined rejection from write should cause pipeTo() to reject when preventCancel is ${preventCancel}`);
|
||||
}
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('general.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="general.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('general.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('general.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1!');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -228,5 +225,3 @@ promise_test(() => {
|
|||
});
|
||||
|
||||
}, 'Piping from a closed readable stream to a closed writable stream');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>multiple-propagation.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('multiple-propagation.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>multiple-propagation.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="multiple-propagation.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>multiple-propagation.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('multiple-propagation.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>multiple-propagation.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('multiple-propagation.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/rs-utils.js
|
||||
// META: script=../resources/test-utils.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/rs-utils.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
}
|
||||
|
||||
function duckTypedPassThroughTransform() {
|
||||
let enqueueInReadable;
|
||||
let closeReadable;
|
||||
|
@ -257,5 +254,3 @@ test(() => {
|
|||
assert_equals(count, 1, 'pipeTo was called once');
|
||||
|
||||
}, 'pipeThrough should work with no options argument');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>pipe-through.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('pipe-through.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>pipe-through.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/rs-utils.js"></script>
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
|
||||
<script src="pipe-through.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>pipe-through.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('pipe-through.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>pipe-through.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('pipe-through.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
// META: script=../resources/recording-streams.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('../resources/recording-streams.js');
|
||||
}
|
||||
|
||||
function interceptThen() {
|
||||
const intercepted = [];
|
||||
const callCount = 0;
|
||||
|
@ -63,5 +60,3 @@ promise_test(async () => {
|
|||
assert_array_equals(intercepted, [], 'nothing should have been intercepted');
|
||||
assert_array_equals(ws.events, ['write', 'a', 'close'], 'written chunk should be "a"');
|
||||
}, 'tee should not be observable');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>then-interception.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('then-interception.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>then-interception.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
<script src="../resources/recording-streams.js"></script>
|
||||
|
||||
<script src="then-interception.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>then-interception.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('then-interception.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>then-interception.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('then-interception.js'));
|
||||
</script>
|
|
@ -1,9 +1,6 @@
|
|||
// META: global=worker
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
promise_test(() => {
|
||||
const rs = new ReadableStream({
|
||||
start(c) {
|
||||
|
@ -23,5 +20,3 @@ promise_test(() => {
|
|||
return writer.closed;
|
||||
});
|
||||
}, 'Piping through an identity transform stream should close the destination when the source closes');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>transform-streams.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('transform-streams.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>transform-streams.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
|
||||
|
||||
<script src="transform-streams.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>transform-streams.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('transform-streams.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>transform-streams.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('transform-streams.js'));
|
||||
</script>
|
|
@ -1,10 +1,7 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/test-utils.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
let ReadableStreamBYOBReader;
|
||||
let ReadableByteStreamController;
|
||||
|
||||
|
@ -190,5 +187,3 @@ promise_test(t => {
|
|||
}
|
||||
|
||||
}, 'ReadableStreamBYOBRequest enforces brand checks');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>brand-checks.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('brand-checks.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>brand-checks.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
|
||||
<script src="brand-checks.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>brand-checks.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('brand-checks.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>brand-checks.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('brand-checks.js'));
|
||||
</script>
|
|
@ -1,14 +1,11 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/rs-utils.js
|
||||
'use strict';
|
||||
|
||||
// Prior to whatwg/stream#870 it was possible to construct a ReadableStreamBYOBRequest directly. This made it possible
|
||||
// to construct requests that were out-of-sync with the state of the ReadableStream. They could then be used to call
|
||||
// internal operations, resulting in asserts or bad behaviour. This file contains regression tests for the change.
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('../resources/rs-utils.js');
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
function getRealByteStreamController() {
|
||||
let controller;
|
||||
new ReadableStream({
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>construct-byob-request.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('construct-byob-request.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>construct-byob-request.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/rs-utils.js"></script>
|
||||
|
||||
<script src="construct-byob-request.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>construct-byob-request.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('construct-byob-request.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>construct-byob-request.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('construct-byob-request.js'));
|
||||
</script>
|
|
@ -1,10 +1,7 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/constructor-ordering.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
self.importScripts('../resources/constructor-ordering.js');
|
||||
}
|
||||
|
||||
const operations = [
|
||||
op('get', 'size'),
|
||||
op('get', 'highWaterMark'),
|
||||
|
@ -49,5 +46,3 @@ for (const failureOp of operations) {
|
|||
'operations should be performed in the right order');
|
||||
}, `ReadableStream constructor should stop after ${failureOp} fails`);
|
||||
}
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>constructor.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('constructor.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>constructor.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/constructor-ordering.js"></script>
|
||||
|
||||
<script src="constructor.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>constructor.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('constructor.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>constructor.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('constructor.js'));
|
||||
</script>
|
|
@ -1,9 +1,6 @@
|
|||
// META: global=worker
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
promise_test(() => {
|
||||
const stream = new ReadableStream({
|
||||
start(c) {
|
||||
|
@ -152,5 +149,3 @@ async_test(t => {
|
|||
reader.read(new Uint8Array([4, 5, 6]));
|
||||
}, 'ReadableStream with byte source: respondWithNewView() throws if the supplied view\'s buffer has been detached ' +
|
||||
'(in the closed state)');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>detached-buffers.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('detached-buffers.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>detached-buffers.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
|
||||
|
||||
<script src="detached-buffers.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>detached-buffers.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('detached-buffers.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>detached-buffers.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('detached-buffers.js'));
|
||||
</script>
|
|
@ -1,11 +1,8 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/rs-utils.js
|
||||
// META: script=../resources/test-utils.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('../resources/rs-utils.js');
|
||||
self.importScripts('../resources/test-utils.js');
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
const error1 = new Error('error1');
|
||||
error1.name = 'error1';
|
||||
|
||||
|
@ -2122,5 +2119,3 @@ test(() => {
|
|||
assert_throws(new RangeError(), () => new ReadableStream({ type: 'bytes' }, new HasSizeMethod()),
|
||||
'constructor should throw when size on the prototype chain');
|
||||
}, 'ReadableStream constructor should not accept a strategy with a size defined if type is "bytes"');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('general.js'));
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/rs-utils.js"></script>
|
||||
<script src="../resources/test-utils.js"></script>
|
||||
|
||||
<script src="general.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('general.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>general.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('general.js'));
|
||||
</script>
|
|
@ -1,10 +1,7 @@
|
|||
// META: global=worker
|
||||
// META: script=../resources/rs-utils.js
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('../resources/rs-utils.js');
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
let ReadableStreamBYOBReader;
|
||||
|
||||
test(() => {
|
||||
|
@ -143,5 +140,3 @@ test(() => {
|
|||
assert_equals(controller.error.length, 1, 'releaseLock has 1 parameter');
|
||||
|
||||
}, 'ReadableByteStreamController instances should have the correct list of properties');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>properties.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('properties.js'));
|
||||
</script>
|
|
@ -1,10 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>properties.js browser context wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script src="../resources/rs-utils.js"></script>
|
||||
|
||||
<script src="properties.js"></script>
|
|
@ -1,12 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>properties.js service worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/service-workers/service-worker/resources/test-helpers.sub.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
service_worker_test('properties.js', 'Service worker test setup');
|
||||
</script>
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>properties.js shared worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new SharedWorker('properties.js'));
|
||||
</script>
|
|
@ -1,9 +1,6 @@
|
|||
// META: global=worker
|
||||
'use strict';
|
||||
|
||||
if (self.importScripts) {
|
||||
self.importScripts('/resources/testharness.js');
|
||||
}
|
||||
|
||||
test(() => {
|
||||
|
||||
const theError = new Error('a unique string');
|
||||
|
@ -160,5 +157,3 @@ promise_test(() => {
|
|||
return Promise.all(promises);
|
||||
|
||||
}, 'Readable stream: invalid strategy.size return value');
|
||||
|
||||
done();
|
|
@ -1,11 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<meta charset="utf-8">
|
||||
<title>bad-strategies.js dedicated worker wrapper file</title>
|
||||
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
|
||||
<script>
|
||||
'use strict';
|
||||
fetch_tests_from_worker(new Worker('bad-strategies.js'));
|
||||
</script>
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче