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

Side by Side Diff: pkg/analysis_server/test/analysis/notification_analysis_options_test.dart

Issue 1838933003: Format code in analysis_server (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 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) 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 test.analysis.notification.analysis_options; 5 library test.analysis.notification.analysis_options;
6 6
7 import 'package:analysis_server/plugin/protocol/protocol.dart'; 7 import 'package:analysis_server/plugin/protocol/protocol.dart';
8 import 'package:analysis_server/src/constants.dart'; 8 import 'package:analysis_server/src/constants.dart';
9 import 'package:analysis_server/src/domain_analysis.dart'; 9 import 'package:analysis_server/src/domain_analysis.dart';
10 import 'package:analyzer/src/generated/engine.dart'; 10 import 'package:analyzer/src/generated/engine.dart';
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 var rules = getLints(testContext).map((rule) => rule.name); 290 var rules = getLints(testContext).map((rule) => rule.name);
291 expect(rules, unorderedEquals(lints)); 291 expect(rules, unorderedEquals(lints));
292 } 292 }
293 293
294 verifyStrongMode({bool enabled}) { 294 verifyStrongMode({bool enabled}) {
295 // Verify strong-mode enabled. 295 // Verify strong-mode enabled.
296 expect(testContext.analysisOptions.strongMode, enabled); 296 expect(testContext.analysisOptions.strongMode, enabled);
297 297
298 if (enabled) { 298 if (enabled) {
299 // Should produce a type warning. 299 // Should produce a type warning.
300 expect( 300 expect(errors.map((error) => error.type),
301 errors.map((error) => error.type), 301 unorderedEquals([AnalysisErrorType.STATIC_TYPE_WARNING]));
302 unorderedEquals([
303 AnalysisErrorType.STATIC_TYPE_WARNING
304 ]));
305 } else { 302 } else {
306 // Should only produce a hint. 303 // Should only produce a hint.
307 expect(errors.map((error) => error.type), 304 expect(errors.map((error) => error.type),
308 unorderedEquals([AnalysisErrorType.HINT])); 305 unorderedEquals([AnalysisErrorType.HINT]));
309 } 306 }
310 } 307 }
311 } 308 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698