Make --trusted default when running spack gpg list (#5678)
* Make --trusted default when running spack gpg list Currently running `spack gpg list` with no arguments returns nothing. You must supply either the `--trusted` or the `--signing` options. The idea here is to return some initial data to the user when the command is run. The alternative is to return an error, telling the user to select one of the two options. * Add an extra test case for the empty list command Fixes the issue with code coverage
This commit is contained in:
parent
65b38764ae
commit
0dad5b3ee5
2 changed files with 2 additions and 1 deletions
|
@ -82,7 +82,7 @@ def setup_parser(subparser):
|
|||
|
||||
list = subparsers.add_parser('list')
|
||||
list.add_argument('--trusted', action='store_true',
|
||||
help='list trusted keys')
|
||||
default=True, help='list trusted keys')
|
||||
list.add_argument('--signing', action='store_true',
|
||||
help='list keys which may be used for signing')
|
||||
list.set_defaults(func=gpg_list)
|
||||
|
|
|
@ -98,6 +98,7 @@ def test_gpg(gpg, tmpdir, testing_gpg_directory):
|
|||
|
||||
# List the keys.
|
||||
# TODO: Test the output here.
|
||||
gpg('list')
|
||||
gpg('list', '--trusted')
|
||||
gpg('list', '--signing')
|
||||
|
||||
|
|
Loading…
Reference in a new issue