mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Migrate command line parsing to argparse (#50610)
* Start of migration to argparse * various fixes and improvements * Linting fixes * Test fixes * Fix vault_password_files * Add PrependAction for argparse * A bunch of additional tweak/fixes * Fix ansible-config tests * Fix man page generation * linting fix * More adhoc pattern fixes * Add changelog fragment * Add support for argcomplete * Enable argcomplete global completion * Rename PrependAction to PrependListAction to better describe what it does * Add documentation for installing and configuring argcomplete * Address rebase issues * Fix display encoding for vault * Fix line length * Address rebase issues * Handle rebase issues * Use mutually exclusive group instead of handling manually * Fix rebase issues * Address rebase issue * Update version added for argcomplete support * -e must be given a value * ci_complete
This commit is contained in:
@@ -41,9 +41,8 @@ class TestVaultCli(unittest.TestCase):
|
||||
|
||||
def test_parse_empty(self):
|
||||
cli = VaultCLI([])
|
||||
self.assertRaisesRegexp(errors.AnsibleOptionsError,
|
||||
'.*Missing required action.*',
|
||||
cli.parse)
|
||||
self.assertRaises(SystemExit,
|
||||
cli.parse)
|
||||
|
||||
# FIXME: something weird seems to be afoot when parsing actions
|
||||
# cli = VaultCLI(args=['view', '/dev/null/foo', 'mysecret3'])
|
||||
|
||||
Reference in New Issue
Block a user