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

Side by Side Diff: test/integration_test.dart

Issue 1918933002: Fix for default filter (#228). (Closed) Base URL: https://github.com/dart-lang/linter.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « bin/linter.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 linter.test.integration; 5 library linter.test.integration;
6 6
7 import 'dart:convert'; 7 import 'dart:convert';
8 import 'dart:io'; 8 import 'dart:io';
9 9
10 import 'package:linter/src/config.dart'; 10 import 'package:linter/src/config.dart';
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 stringContainsInOrder( 46 stringContainsInOrder(
47 ['4 files analyzed, 1 issue found (2 filtered), in'])); 47 ['4 files analyzed, 1 issue found (2 filtered), in']));
48 }); 48 });
49 test('overrrides', () { 49 test('overrrides', () {
50 dartlint 50 dartlint
51 .main(['test/_data/p2', '-c', 'test/_data/p2/lintconfig2.yaml']); 51 .main(['test/_data/p2', '-c', 'test/_data/p2/lintconfig2.yaml']);
52 expect(exitCode, 0); 52 expect(exitCode, 0);
53 expect(collectingOut.trim(), 53 expect(collectingOut.trim(),
54 stringContainsInOrder(['4 files analyzed, 0 issues found, in'])); 54 stringContainsInOrder(['4 files analyzed, 0 issues found, in']));
55 }); 55 });
56 test('default', () {
57 dartlint.main(['test/_data/p2']);
58 expect(exitCode, 1);
59 expect(collectingOut.trim(),
60 stringContainsInOrder(['4 files analyzed, 3 issues found, in']));
61 });
56 }); 62 });
57 }); 63 });
58 group('p3', () { 64 group('p3', () {
59 IOSink currentOut = outSink; 65 IOSink currentOut = outSink;
60 CollectingSink collectingOut = new CollectingSink(); 66 CollectingSink collectingOut = new CollectingSink();
61 setUp(() => outSink = collectingOut); 67 setUp(() => outSink = collectingOut);
62 tearDown(() { 68 tearDown(() {
63 collectingOut.buffer.clear(); 69 collectingOut.buffer.clear();
64 outSink = currentOut; 70 outSink = currentOut;
65 }); 71 });
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 var ruleConfig = config.ruleConfigs[0]; 161 var ruleConfig = config.ruleConfigs[0];
156 expect(ruleConfig.group, 'style_guide'); 162 expect(ruleConfig.group, 'style_guide');
157 expect(ruleConfig.name, 'unnecessary_getters'); 163 expect(ruleConfig.name, 'unnecessary_getters');
158 expect(ruleConfig.args, {'enabled': false}); 164 expect(ruleConfig.args, {'enabled': false});
159 }); 165 });
160 }); 166 });
161 }); 167 });
162 } 168 }
163 169
164 class MockProcessResult extends Mock implements ProcessResult {} 170 class MockProcessResult extends Mock implements ProcessResult {}
OLDNEW
« no previous file with comments | « bin/linter.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698