OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #library("PromiseBasedTest"); | 5 #library("PromiseBasedTest"); |
| 6 #import("dart:isolate"); |
6 #import("../../../../proxy/promise.dart"); | 7 #import("../../../../proxy/promise.dart"); |
7 #import("../../../../../tests/isolate/src/TestFramework.dart"); | 8 #import("../../../../../tests/isolate/src/TestFramework.dart"); |
8 | 9 |
9 class TestIsolate extends Isolate { | 10 class TestIsolate extends Isolate { |
10 | 11 |
11 TestIsolate() : super(); | 12 TestIsolate() : super(); |
12 | 13 |
13 void main() { | 14 void main() { |
14 int seed = 0; | 15 int seed = 0; |
15 this.port.receive((var message, SendPort replyTo) { | 16 this.port.receive((var message, SendPort replyTo) { |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 expect.completes(completer.future).then((int value) { | 77 expect.completes(completer.future).then((int value) { |
77 //print("expect 2: $value"); | 78 //print("expect 2: $value"); |
78 Expect.equals(99, value); | 79 Expect.equals(99, value); |
79 expect.succeeded(); | 80 expect.succeeded(); |
80 }); | 81 }); |
81 } | 82 } |
82 | 83 |
83 void main() { | 84 void main() { |
84 runTests([test, expandedTest]); | 85 runTests([test, expandedTest]); |
85 } | 86 } |
OLD | NEW |