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

Unified Diff: tests/compiler/dart2js/generate_code_with_compile_time_errors_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/generate_code_with_compile_time_errors_test.dart
diff --git a/tests/compiler/dart2js/generate_code_with_compile_time_errors_test.dart b/tests/compiler/dart2js/generate_code_with_compile_time_errors_test.dart
index a1814d7eafc85a2ffe546e1a6ea53d5f422c4c69..8654db504dd166f10c45b65f6c09e243648075c8 100644
--- a/tests/compiler/dart2js/generate_code_with_compile_time_errors_test.dart
+++ b/tests/compiler/dart2js/generate_code_with_compile_time_errors_test.dart
@@ -27,9 +27,9 @@ main() {
};
test(List<String> options,
- {bool expectedOutput,
- bool expectedCodeGenerated,
- bool expectHint: false}) async {
+ {bool expectedOutput,
+ bool expectedCodeGenerated,
+ bool expectHint: false}) async {
DiagnosticCollector collector = new DiagnosticCollector();
OutputCollector outputCollector = new OutputCollector();
CompilationResult result = await runCompiler(
@@ -38,18 +38,11 @@ test(List<String> options,
outputProvider: outputCollector,
options: options);
Compiler compiler = result.compiler;
- Expect.isFalse(
- result.isSuccess,
- "Expected compilation failure.");
+ Expect.isFalse(result.isSuccess, "Expected compilation failure.");
Expect.isTrue(
- collector.warnings.isEmpty,
- "Unexpected warnings: ${collector.warnings}");
- Expect.isFalse(
- collector.errors.isEmpty,
- "Expected compile-time errors.");
- Expect.equals(
- expectHint,
- collector.hints.isNotEmpty,
+ collector.warnings.isEmpty, "Unexpected warnings: ${collector.warnings}");
+ Expect.isFalse(collector.errors.isEmpty, "Expected compile-time errors.");
+ Expect.equals(expectHint, collector.hints.isNotEmpty,
"Unexpected hints: ${collector.warnings}");
JavaScriptBackend backend = compiler.backend;
@@ -70,21 +63,12 @@ test(List<String> options,
void main() {
asyncTest(() async {
- await test(
- [],
- expectedCodeGenerated: false,
- expectedOutput: false);
- await test(
- ['--test-mode'],
- expectedCodeGenerated: false,
- expectedOutput: false);
- await test(
- ['--generate-code-with-compile-time-errors'],
- expectedCodeGenerated: true,
- expectedOutput: true);
- await test(
- ['--generate-code-with-compile-time-errors', '--test-mode'],
- expectedCodeGenerated: true,
- expectedOutput: false);
+ await test([], expectedCodeGenerated: false, expectedOutput: false);
+ await test(['--test-mode'],
+ expectedCodeGenerated: false, expectedOutput: false);
+ await test(['--generate-code-with-compile-time-errors'],
+ expectedCodeGenerated: true, expectedOutput: true);
+ await test(['--generate-code-with-compile-time-errors', '--test-mode'],
+ expectedCodeGenerated: true, expectedOutput: false);
});
}
« no previous file with comments | « tests/compiler/dart2js/generate_at_use_site_test.dart ('k') | tests/compiler/dart2js/generic_method_type_usage_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698