Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(336)

Unified Diff: tests/isolate/src/IsolateComplexMessagesTest.dart

Issue 10153005: unittest step 3 and 4: remove TestFramework.dart, make test.dart use (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/isolate/src/Isolate3NegativeTest.dart ('k') | tests/isolate/src/IsolateNegativeTest.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/isolate/src/IsolateComplexMessagesTest.dart
diff --git a/tests/isolate/src/IsolateComplexMessagesTest.dart b/tests/isolate/src/IsolateComplexMessagesTest.dart
index 135f7c6836af37cc840a72c5cd159f3a1517389c..f19d444ddee064c09556d42fc832c334d4ce7797 100644
--- a/tests/isolate/src/IsolateComplexMessagesTest.dart
+++ b/tests/isolate/src/IsolateComplexMessagesTest.dart
@@ -7,22 +7,22 @@
#library('IsolateComplexMessagesTest');
#import('dart:isolate');
-#import('TestFramework.dart');
+#import('../../../lib/unittest/unittest.dart');
+main() {
+ test("complex messages are serialized correctly", () {
+ new LogIsolate().spawn().then(expectAsync1((SendPort remote) {
-void test(TestExpectation expect) {
- expect.completes(new LogIsolate().spawn()).then((SendPort remote) {
-
- remote.send(1, null);
- remote.send("Hello", null);
- remote.send("World", null);
- remote.send(const [null, 1, 2, 3, 4], null);
- remote.send(const [1, 2.0, true, false, 0xffffffffff], null);
- remote.send(const ["Hello", "World", 0xffffffffff], null);
- // Shutdown the LogRunner.
- remote.call(-1).then(expect.runs1((int message) {
- Expect.equals(6, message);
- expect.succeeded();
+ remote.send(1, null);
+ remote.send("Hello", null);
+ remote.send("World", null);
+ remote.send(const [null, 1, 2, 3, 4], null);
+ remote.send(const [1, 2.0, true, false, 0xffffffffff], null);
+ remote.send(const ["Hello", "World", 0xffffffffff], null);
+ // Shutdown the LogRunner.
+ remote.call(-1).then(expectAsync1((int message) {
+ Expect.equals(6, message);
+ }));
}));
});
}
@@ -77,7 +77,3 @@ class LogIsolate extends Isolate {
});
}
}
-
-main() {
- runTests([test]);
-}
« no previous file with comments | « tests/isolate/src/Isolate3NegativeTest.dart ('k') | tests/isolate/src/IsolateNegativeTest.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698