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

Side by Side Diff: pkg/kernel/test/interpreter/suite.dart

Issue 2975253002: Format analyzer, analysis_server, analyzer_plugin, front_end and kernel with the latest dartfmt. (Closed)
Patch Set: Created 3 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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.md file. 3 // BSD-style license that can be found in the LICENSE.md file.
4 4
5 library test.kernel.closures.suite; 5 library test.kernel.closures.suite;
6 6
7 import 'dart:async' show Future; 7 import 'dart:async' show Future;
8 8
9 import 'dart:io' show File; 9 import 'dart:io' show File;
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 if (await expectedFile.exists()) { 75 if (await expectedFile.exists()) {
76 String expected = await expectedFile.readAsString(); 76 String expected = await expectedFile.readAsString();
77 if (expected.trim() != result.log.trim()) { 77 if (expected.trim() != result.log.trim()) {
78 String diff = await runDiff(expectedFile.uri, result.log); 78 String diff = await runDiff(expectedFile.uri, result.log);
79 return fail(null, "$uri doesn't match ${expectedFile.uri}\n$diff"); 79 return fail(null, "$uri doesn't match ${expectedFile.uri}\n$diff");
80 } else { 80 } else {
81 return pass(0); 81 return pass(0);
82 } 82 }
83 } 83 }
84 return fail( 84 return fail(
85 null, 85 null, """Please create file ${expectedFile.path} with this content:
86 """Please create file ${expectedFile.path} with this content:
87 ${result.log}"""); 86 ${result.log}""");
88 } 87 }
89 } 88 }
90 89
91 class EvaluationLog { 90 class EvaluationLog {
92 /// Evaluated program uri. 91 /// Evaluated program uri.
93 final Uri uri; 92 final Uri uri;
94 93
95 /// Evaluated program log. 94 /// Evaluated program log.
96 final String log; 95 final String log;
97 96
98 EvaluationLog(this.uri, this.log); 97 EvaluationLog(this.uri, this.log);
99 } 98 }
100 99
101 main(List<String> arguments) => 100 main(List<String> arguments) =>
102 runMe(arguments, InterpreterContext.create, "testing.json"); 101 runMe(arguments, InterpreterContext.create, "testing.json");
OLDNEW
« no previous file with comments | « pkg/front_end/test/src/incremental/mock_sdk.dart ('k') | pkg/kernel/test/reify/kernel_chain.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698