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

Unified Diff: pkg/analyzer/test/options_test.dart

Issue 481273003: Add flags for proposed features (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/lib/src/analyzer_impl.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/test/options_test.dart
diff --git a/pkg/analyzer/test/options_test.dart b/pkg/analyzer/test/options_test.dart
index 96270a9e5d2baac9a10b2790169762560f0fa274..bb2ba2a596855796a8df5098af421bc3d19641e7 100644
--- a/pkg/analyzer/test/options_test.dart
+++ b/pkg/analyzer/test/options_test.dart
@@ -15,18 +15,22 @@ main() {
CommandLineOptions options = CommandLineOptions
.parse(['--dart-sdk', '.', 'foo.dart']);
expect(options, isNotNull);
- expect(options.shouldBatch, isFalse);
- expect(options.machineFormat, isFalse);
- expect(options.displayVersion, isFalse);
+ expect(options.dartSdkPath, isNotNull);
expect(options.disableHints, isFalse);
+ expect(options.displayVersion, isFalse);
+ expect(options.enableAsync, isFalse);
+ expect(options.enableEnum, isFalse);
expect(options.ignoreUnrecognizedFlags, isFalse);
+ expect(options.log, isFalse);
+ expect(options.machineFormat, isFalse);
+ expect(options.packageRootPath, isNull);
expect(options.perf, isFalse);
+ expect(options.shouldBatch, isFalse);
expect(options.showPackageWarnings, isFalse);
expect(options.showSdkWarnings, isFalse);
- expect(options.warningsAreFatal, isFalse);
- expect(options.dartSdkPath, isNotNull);
- expect(options.log, isFalse);
expect(options.sourceFiles, equals(['foo.dart']));
+ expect(options.warmPerf, isFalse);
+ expect(options.warningsAreFatal, isFalse);
});
test('batch', () {
@@ -42,6 +46,18 @@ main() {
expect(options.definedVariables['bar'], isNull);
});
+ test('enable async', () {
+ CommandLineOptions options = CommandLineOptions
+ .parse(['--dart-sdk', '.', '--enable-async', 'foo.dart']);
+ expect(options.enableAsync, isTrue);
+ });
+
+ test('enable enum', () {
+ CommandLineOptions options = CommandLineOptions
+ .parse(['--dart-sdk', '.', '--enable-enum', 'foo.dart']);
+ expect(options.enableEnum, isTrue);
+ });
+
test('log', () {
CommandLineOptions options = CommandLineOptions
.parse(['--dart-sdk', '.', '--log', 'foo.dart']);
« no previous file with comments | « pkg/analyzer/lib/src/analyzer_impl.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698