| Index: tests/isolate/src/ConstructorTest.dart
|
| diff --git a/tests/isolate/src/ConstructorTest.dart b/tests/isolate/src/ConstructorTest.dart
|
| index 7e0323890dad27c0d96fa4d799b3d68c6dcbe8fe..c467e427fc297c6a20fd9a20083eb40eba3acb5a 100644
|
| --- a/tests/isolate/src/ConstructorTest.dart
|
| +++ b/tests/isolate/src/ConstructorTest.dart
|
| @@ -4,7 +4,7 @@
|
|
|
| #library("ConstructorTest");
|
| #import("dart:isolate");
|
| -#import('../../../lib/unittest/unittest.dart');
|
| +#import("TestFramework.dart");
|
|
|
| class ConstructorTest extends Isolate {
|
| final int field;
|
| @@ -18,13 +18,16 @@ class ConstructorTest extends Isolate {
|
| }
|
| }
|
|
|
| -main() {
|
| - test("constructor correctly initialized child isolate", () {
|
| - ConstructorTest test = new ConstructorTest();
|
| - test.spawn().then(expectAsync1((SendPort port) {
|
| - port.call("ignored").then(expectAsync1((message) {
|
| - Expect.equals(499, message);
|
| - }));
|
| +void test(TestExpectation expect) {
|
| + ConstructorTest test = new ConstructorTest();
|
| + expect.completes(test.spawn()).then((SendPort port) {
|
| + port.call("ignored").then(expect.runs1((message) {
|
| + Expect.equals(499, message);
|
| + expect.succeeded();
|
| }));
|
| });
|
| }
|
| +
|
| +main() {
|
| + runTests([test]);
|
| +}
|
|
|