| Index: third_party/WebKit/LayoutTests/fast/workers/resources/worker-xhr-microtasks.js
|
| diff --git a/third_party/WebKit/LayoutTests/fast/workers/resources/worker-xhr-microtasks.js b/third_party/WebKit/LayoutTests/fast/workers/resources/worker-xhr-microtasks.js
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..f60dad173fcdd4e995269af066818e5fa5107232
|
| --- /dev/null
|
| +++ b/third_party/WebKit/LayoutTests/fast/workers/resources/worker-xhr-microtasks.js
|
| @@ -0,0 +1,13 @@
|
| +onmessage = function(evt) {
|
| + new Promise(function(res,rej) { res(); }).then(function() {
|
| + var xhr = new XMLHttpRequest();
|
| + xhr.open("GET", "http://example.test", false);
|
| + try {
|
| + xhr.send();
|
| + console.log("FAIL: xhr.send() didn't throw");
|
| + } catch (e) {
|
| + console.log("PASS: xhr.send() throws as expected");
|
| + }
|
| + postMessage("done");
|
| + });
|
| +};
|
|
|