Index: pkg/args/test/usage_test.dart |
diff --git a/pkg/args/test/usage_test.dart b/pkg/args/test/usage_test.dart |
index ddd223c904b41f5d4197fb77634c98f0f920839a..77d66a83153c630248e6104d56547f7cc6d5e09f 100644 |
--- a/pkg/args/test/usage_test.dart |
+++ b/pkg/args/test/usage_test.dart |
@@ -177,8 +177,8 @@ void main() { |
validateUsage(parser, |
''' |
- --first The first option |
- --third The third option |
+ --first The first option |
+ --third The third option |
'''); |
}); |
@@ -191,8 +191,22 @@ void main() { |
validateUsage(parser, |
''' |
- --[no-]first The first flag |
- --[no-]third The third flag |
+ --[no-]first The first flag |
+ --[no-]third The third flag |
+ '''); |
+ }); |
+ |
+ test("hidden options don't affect spacing", () { |
+ var parser = new ArgParser(); |
+ parser.addFlag('first', help: 'The first flag'); |
+ parser.addFlag('second-very-long-option', hide: true); |
+ parser.addFlag('third', help: 'The third flag'); |
+ |
+ |
+ validateUsage(parser, |
+ ''' |
+ --[no-]first The first flag |
+ --[no-]third The third flag |
'''); |
}); |
}); |