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

Unified Diff: pkg/analysis_server/test/analysis_server_test.dart

Issue 1462693002: Report error for ignored priority file. Ignore subscription for ignored files. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: pkg/analysis_server/test/analysis_server_test.dart
diff --git a/pkg/analysis_server/test/analysis_server_test.dart b/pkg/analysis_server/test/analysis_server_test.dart
index 5275d3a43298137625bb20434ea85848fd722920..0575280efb24abc502c6a3a26e77e61ff01c131b 100644
--- a/pkg/analysis_server/test/analysis_server_test.dart
+++ b/pkg/analysis_server/test/analysis_server_test.dart
@@ -456,6 +456,27 @@ import "../foo/foo.dart";
});
}
+ test_setAnalysisSubscriptions_fileInIgnoredFolder() async {
+ String path = '/project/samples/sample.dart';
+ resourceProvider.newFile(path, '');
+ resourceProvider.newFile(
+ '/project/.analysis_options',
+ r'''
+analyzer:
+ exclude:
+ - 'samples/**'
+''');
+ server.setAnalysisRoots('0', ['/project'], [], {});
+ server.setAnalysisSubscriptions(<AnalysisService, Set<String>>{
+ AnalysisService.NAVIGATION: new Set<String>.from([path])
+ });
+ // the file is excluded, so no navigation notification
+ await server.onAnalysisComplete;
+ expect(channel.notificationsReceived.any((notification) {
+ return notification.event == ANALYSIS_NAVIGATION;
+ }), isFalse);
+ }
+
Future test_shutdown() {
server.handlers = [new ServerDomainHandler(server)];
var request = new Request('my28', SERVER_SHUTDOWN);

Powered by Google App Engine
This is Rietveld 408576698