Index: client/tests/client/dom/DOMIsolatesTest.dart |
diff --git a/client/tests/client/dom/DOMIsolatesTest.dart b/client/tests/client/dom/DOMIsolatesTest.dart |
deleted file mode 100644 |
index 542145cba17b87c45fb26036921836e4554efa81..0000000000000000000000000000000000000000 |
--- a/client/tests/client/dom/DOMIsolatesTest.dart |
+++ /dev/null |
@@ -1,60 +0,0 @@ |
-#library('DOMIsolatesTest'); |
-#import('../../../../lib/unittest/unittest.dart'); |
-#import('../../../../lib/unittest/dom_config.dart'); |
-#import('dart:dom'); |
-#import('dart:isolate'); |
- |
-isolateMain(port) { |
- port.receive((msg, replyTo) { |
- if (msg != 'check') { |
- replyTo.send('wrong msg: $msg'); |
- } |
- replyTo.send(window.location.toString()); |
- port.close(); |
- }); |
-} |
- |
-isolateMainTrampoline(port) { |
- final childPortFuture = spawnDomIsolate(window, 'isolateMain'); |
- port.receive((msg, parentPort) { |
- childPortFuture.then((childPort) { |
- childPort.call(msg).then((response) { |
- parentPort.send(response); |
- port.close(); |
- }); |
- }); |
- }); |
-} |
- |
-main() { |
- useDomConfiguration(); |
- |
- final iframe = document.createElement('iframe'); |
- document.body.appendChild(iframe); |
- |
- asyncTest('Simple DOM isolate test', 1, () { |
- spawnDomIsolate(iframe.contentWindow, 'isolateMain').then((sendPort) { |
- sendPort.call('check').then((msg) { |
- Expect.equals('about:blank', msg); |
- callbackDone(); |
- }); |
- }); |
- }); |
- |
- asyncTest('Nested DOM isolates test', 1, () { |
- spawnDomIsolate(iframe.contentWindow, 'isolateMainTrampoline').then((sendPort) { |
- sendPort.call('check').then((msg) { |
- Expect.equals('about:blank', msg); |
- callbackDone(); |
- }); |
- }); |
- }); |
- |
- test('Null as target window', () { |
- expectThrow(() => spawnDomIsolate(null, 'isolateMain')); |
- }); |
- |
- test('Not window as target window', () { |
- expectThrow(() => spawnDomIsolate(document, 'isolateMain')); |
- }); |
-} |