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); |
}); |
} |