| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library analyzer_cli.test.driver; | 5 library analyzer_cli.test.driver; |
| 6 | 6 |
| 7 import 'dart:io'; | 7 import 'dart:io'; |
| 8 | 8 |
| 9 import 'package:analyzer/plugin/options.dart'; | 9 import 'package:analyzer/plugin/options.dart'; |
| 10 import 'package:analyzer/source/analysis_options_provider.dart'; | 10 import 'package:analyzer/source/analysis_options_provider.dart'; |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 outSink = savedOutSink; | 44 outSink = savedOutSink; |
| 45 errorSink = savedErrorSink; | 45 errorSink = savedErrorSink; |
| 46 exitCode = savedExitCode; | 46 exitCode = savedExitCode; |
| 47 exitHandler = savedExitHandler; | 47 exitHandler = savedExitHandler; |
| 48 } | 48 } |
| 49 | 49 |
| 50 setUp(() => _setUp()); | 50 setUp(() => _setUp()); |
| 51 | 51 |
| 52 tearDown(() => _tearDown()); | 52 tearDown(() => _tearDown()); |
| 53 | 53 |
| 54 initializeTestEnvironment(); |
| 55 |
| 54 group('Driver', () { | 56 group('Driver', () { |
| 55 group('options', () { | 57 group('options', () { |
| 56 test('custom processor', () { | 58 test('custom processor', () { |
| 57 Driver driver = new Driver(); | 59 Driver driver = new Driver(); |
| 58 TestProcessor processor = new TestProcessor(); | 60 TestProcessor processor = new TestProcessor(); |
| 59 driver.userDefinedPlugins = [new TestPlugin(processor)]; | 61 driver.userDefinedPlugins = [new TestPlugin(processor)]; |
| 60 driver.start([ | 62 driver.start([ |
| 61 '--options', | 63 '--options', |
| 62 path.join(testDirectory, 'data/test_options.yaml'), | 64 path.join(testDirectory, 'data/test_options.yaml'), |
| 63 path.join(testDirectory, 'data/test_file.dart') | 65 path.join(testDirectory, 'data/test_file.dart') |
| (...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 423 this.options = options; | 425 this.options = options; |
| 424 } | 426 } |
| 425 } | 427 } |
| 426 | 428 |
| 427 class TestSource implements Source { | 429 class TestSource implements Source { |
| 428 TestSource(); | 430 TestSource(); |
| 429 | 431 |
| 430 @override | 432 @override |
| 431 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); | 433 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); |
| 432 } | 434 } |
| OLD | NEW |