Index: pkg/analyzer_cli/test/super_mixin_test.dart |
diff --git a/pkg/analyzer_cli/test/super_mixin_test.dart b/pkg/analyzer_cli/test/super_mixin_test.dart |
index de1ad1af92355b7db2f46bff3d87fdb33248e952..d5cec87b380244dcaae64a3a4bcd8376975e1989 100644 |
--- a/pkg/analyzer_cli/test/super_mixin_test.dart |
+++ b/pkg/analyzer_cli/test/super_mixin_test.dart |
@@ -6,6 +6,7 @@ library analyzer_cli.test.super_mixin; |
import 'dart:io'; |
+import 'package:analyzer_cli/src/ansi.dart' as ansi; |
import 'package:analyzer_cli/src/driver.dart' show Driver, errorSink, outSink; |
import 'package:path/path.dart' as path; |
import 'package:test/test.dart'; |
@@ -23,17 +24,21 @@ void main() { |
group('--supermixins', () { |
StringSink savedOutSink, savedErrorSink; |
int savedExitCode; |
+ |
setUp(() { |
+ ansi.runningTests = true; |
savedOutSink = outSink; |
savedErrorSink = errorSink; |
savedExitCode = exitCode; |
outSink = new StringBuffer(); |
errorSink = new StringBuffer(); |
}); |
+ |
tearDown(() { |
outSink = savedOutSink; |
errorSink = savedErrorSink; |
exitCode = savedExitCode; |
+ ansi.runningTests = false; |
}); |
test('produces errors when option absent', () async { |
@@ -45,11 +50,11 @@ void main() { |
expect( |
stdout, |
contains( |
- "[error] The class 'C' can't be used as a mixin because it extends a class other than Object")); |
+ "error • The class 'C' can't be used as a mixin because it extends a class other than Object")); |
expect( |
stdout, |
contains( |
- "[error] The class 'C' can't be used as a mixin because it references 'super'")); |
+ "error • The class 'C' can't be used as a mixin because it references 'super'")); |
expect(stdout, contains('2 errors found.')); |
expect(errorSink.toString(), ''); |
}); |