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

Unified Diff: tests/compiler/dart2js_extra/closure_capture5_test.dart

Issue 2345083003: dart2js: run dartfmt on tests (Closed)
Patch Set: revert another multipart test Created 4 years, 3 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/compiler/dart2js_extra/closure_capture5_test.dart
diff --git a/tests/compiler/dart2js_extra/closure_capture5_test.dart b/tests/compiler/dart2js_extra/closure_capture5_test.dart
index 37df6df2dc56f1a6ba4259fc839a1c036741cab2..c95bbc6862673f981e70e67cf923529ea1e69c67 100644
--- a/tests/compiler/dart2js_extra/closure_capture5_test.dart
+++ b/tests/compiler/dart2js_extra/closure_capture5_test.dart
@@ -7,7 +7,9 @@ import "package:expect/expect.dart";
closure0() {
var fs = [];
for (var x = 1; x <= 3; x++) {
- fs.add(() { return x; });
+ fs.add(() {
+ return x;
+ });
}
Expect.equals(3, fs.length);
Expect.equals(1, fs[0]());
@@ -18,7 +20,9 @@ closure0() {
closure1() {
var fs = [];
for (var x = 0; x < 6; x++) {
- fs.add(() { return x; });
+ fs.add(() {
+ return x;
+ });
x++;
}
Expect.equals(3, fs.length);
@@ -31,7 +35,9 @@ closure2() {
var input = [1, 2, 3];
var fs = [];
for (var i = 0; i < input.length; i++) {
- fs.add(() { return input[i]; });
+ fs.add(() {
+ return input[i];
+ });
}
Expect.equals(3, fs.length);
Expect.equals(1, fs[0]());
@@ -42,11 +48,11 @@ closure2() {
closure3() {
var fs = [];
for (var i = 0;
- i < 3;
- (() {
- fs.add(() => i);
- i++;
- })()) {
+ i < 3;
+ (() {
+ fs.add(() => i);
+ i++;
+ })()) {
i++;
}
Expect.equals(2, fs.length);
@@ -57,11 +63,11 @@ closure3() {
closure4() {
var g;
for (var i = 0;
- (() {
- g = () => i;
- return false;
- })();
- i++){
+ (() {
+ g = () => i;
+ return false;
+ })();
+ i++) {
Expect.equals(false, true);
}
Expect.equals(0, g());
« no previous file with comments | « tests/compiler/dart2js_extra/closure_capture4_test.dart ('k') | tests/compiler/dart2js_extra/closure_capture_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698