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

Side by Side Diff: pkg/analysis_server/test/integration/coverage_test.dart

Issue 2812483002: Add integration tests for edit.getAssists and edit.getFixes. (Closed)
Patch Set: Created 3 years, 8 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
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 import 'dart:io'; 5 import 'dart:io';
6 6
7 import 'package:analysis_server/src/services/correction/strings.dart'; 7 import 'package:analysis_server/src/services/correction/strings.dart';
8 import 'package:path/path.dart' as path; 8 import 'package:path/path.dart' as path;
9 import 'package:test/test.dart'; 9 import 'package:test/test.dart';
10 10
11 import '../../tool/spec/api.dart'; 11 import '../../tool/spec/api.dart';
12 import '../../tool/spec/from_html.dart'; 12 import '../../tool/spec/from_html.dart';
13 13
14 // TODO(devoncarew): Several of the analysis domain methods are covered, but
15 // they aren't using the below file name pattern.
16
17 /// Define tests to fail if there's no mention in the coverage file. 14 /// Define tests to fail if there's no mention in the coverage file.
18 main() { 15 main() {
19 Api api; 16 Api api;
20 File coverageFile; 17 File coverageFile;
21 String pathPrefix; 18 String pathPrefix;
22 19
23 // parse the API file 20 // parse the API file
24 if (FileSystemEntity 21 if (FileSystemEntity
25 .isFileSync(path.join('tool', 'spec', 'spec_input.html'))) { 22 .isFileSync(path.join('tool', 'spec', 'spec_input.html'))) {
26 api = readApi('.'); 23 api = readApi('.');
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 92
96 // validate no unexpected domains 93 // validate no unexpected domains
97 group('integration coverage', () { 94 group('integration coverage', () {
98 test('no unexpected domains', () { 95 test('no unexpected domains', () {
99 for (String domain in coveredDomains) { 96 for (String domain in coveredDomains) {
100 expect(api.domains.map((d) => d.name), contains(domain)); 97 expect(api.domains.map((d) => d.name), contains(domain));
101 } 98 }
102 }); 99 });
103 }); 100 });
104 } 101 }
OLDNEW
« no previous file with comments | « pkg/analysis_server/test/integration/coverage.md ('k') | pkg/analysis_server/test/integration/edit/get_assists_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698