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

Unified Diff: tests/isolate/issue_21398_parent_isolate_test.dart

Issue 2771453003: Format all tests. (Closed)
Patch Set: Format files Created 3 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
Index: tests/isolate/issue_21398_parent_isolate_test.dart
diff --git a/tests/isolate/issue_21398_parent_isolate_test.dart b/tests/isolate/issue_21398_parent_isolate_test.dart
index 76e7e0d4436b57a3762453270ec48b04215e6650..967d25fda32ab0efa149944fccf365be3cb76ddf 100644
--- a/tests/isolate/issue_21398_parent_isolate_test.dart
+++ b/tests/isolate/issue_21398_parent_isolate_test.dart
@@ -31,46 +31,34 @@ main() {
// First spawn an isolate using spawnURI and have it
// send back a "non-literal" like object.
asyncStart();
- Isolate.spawnUri(Uri.parse('issue_21398_child_isolate.dart'),
- [],
- [new FromMainIsolate(), receive1.sendPort]).catchError(
- (error) {
- Expect.isTrue(error is ArgumentError);
- asyncEnd();
- }
- );
+ Isolate.spawnUri(Uri.parse('issue_21398_child_isolate.dart'), [],
+ [new FromMainIsolate(), receive1.sendPort]).catchError((error) {
+ Expect.isTrue(error is ArgumentError);
+ asyncEnd();
+ });
asyncStart();
- Isolate.spawnUri(Uri.parse('issue_21398_child_isolate.dart'),
- [],
- receive1.sendPort).then(
- (isolate) {
- receive1.listen(
- (msg) {
- Expect.stringEquals(msg, "Invalid Argument(s).");
- receive1.close();
- asyncEnd();
- },
- onError: (e) => print('$e')
- );
- }
- );
+ Isolate
+ .spawnUri(
+ Uri.parse('issue_21398_child_isolate.dart'), [], receive1.sendPort)
+ .then((isolate) {
+ receive1.listen((msg) {
+ Expect.stringEquals(msg, "Invalid Argument(s).");
+ receive1.close();
+ asyncEnd();
+ }, onError: (e) => print('$e'));
+ });
// Now spawn an isolate using spawnFunction and send it a "non-literal"
// like object and also have the child isolate send back a "non-literal"
// like object.
asyncStart();
- Isolate.spawn(funcChild,
- [new FromMainIsolate(), receive2.sendPort]).then(
- (isolate) {
- receive2.listen(
- (msg) {
- Expect.isTrue(msg is FromMainIsolate);
- Expect.equals(10, msg.fld);
- receive2.close();
- asyncEnd();
- },
- onError: (e) => print('$e')
- );
- }
- );
+ Isolate.spawn(funcChild, [new FromMainIsolate(), receive2.sendPort]).then(
+ (isolate) {
+ receive2.listen((msg) {
+ Expect.isTrue(msg is FromMainIsolate);
+ Expect.equals(10, msg.fld);
+ receive2.close();
+ asyncEnd();
+ }, onError: (e) => print('$e'));
+ });
}

Powered by Google App Engine
This is Rietveld 408576698