| Index: utils/tests/pub/pub_test.dart
|
| diff --git a/utils/tests/pub/pub_test.dart b/utils/tests/pub/pub_test.dart
|
| index 55c93c45191cc7fe2b7b89f9def8bd30e1a6f211..b84a0dc7fa6aac9e29cbd7a747168abab1f7afae 100644
|
| --- a/utils/tests/pub/pub_test.dart
|
| +++ b/utils/tests/pub/pub_test.dart
|
| @@ -9,26 +9,42 @@
|
| #import('test_pub.dart');
|
| #import('../../../lib/unittest/unittest.dart');
|
|
|
| -main() {
|
| - group('running pub with no command', () {
|
| - testPub('displays usage',
|
| - args: [],
|
| - output: """
|
| - Pub is a package manager for Dart.
|
| +final USAGE_STRING = """
|
| + Pub is a package manager for Dart.
|
|
|
| - Usage:
|
| + Usage:
|
|
|
| - pub command [arguments]
|
| + pub command [arguments]
|
|
|
| - The commands are:
|
| + The commands are:
|
|
|
| - list print the contents of repositories
|
| - update update a package's dependencies
|
| - version print Pub version
|
| + list print the contents of repositories
|
| + update update the current package's dependencies to the latest versions
|
| + version print Pub version
|
|
|
| - Use "pub help [command]" for more information about a command.
|
| - """);
|
| - });
|
| + Use "pub help [command]" for more information about a command.
|
| + """;
|
| +
|
| +final VERSION_STRING = '''
|
| + Pub 0.0.0
|
| + ''';
|
| +
|
| +main() {
|
| + testPub('running pub with no command displays usage',
|
| + args: [],
|
| + output: USAGE_STRING);
|
| +
|
| + testPub('running pub with just --help displays usage',
|
| + args: ['--help'],
|
| + output: USAGE_STRING);
|
| +
|
| + testPub('running pub with just -h displays usage',
|
| + args: ['-h'],
|
| + output: USAGE_STRING);
|
| +
|
| + testPub('running pub with just --version displays version',
|
| + args: ['--version'],
|
| + output: VERSION_STRING);
|
|
|
| group('an unknown command', () {
|
| testPub('displays an error message',
|
| @@ -108,7 +124,5 @@ updateCommand() {
|
| versionCommand() {
|
| testPub('displays the current version',
|
| args: ['version'],
|
| - output: '''
|
| - Pub 0.0.0
|
| - ''');
|
| + output: VERSION_STRING);
|
| }
|
|
|