Skip to content

Commit

Permalink
Minor fixes in galaxy command for collection (ansible#59846)
Browse files Browse the repository at this point in the history
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
  • Loading branch information
Akasurde authored and jborean93 committed Aug 1, 2019
1 parent bb1256c commit 056aac1
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions lib/ansible/cli/galaxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def init_parser(self):
''' create an options parser for bin/ansible '''

super(GalaxyCLI, self).init_parser(
desc="Perform various Role related operations.",
desc="Perform various Role and Collection related operations.",
)

# common
Expand Down Expand Up @@ -413,7 +413,7 @@ def execute_init(self):
obj_name = context.CLIARGS['{0}_name'.format(galaxy_type)]

inject_data = dict(
description='your description',
description='your {0} description'.format(galaxy_type),
ansible_plugin_list_dir=get_versioned_doclink('plugins/plugins.html'),
)
if galaxy_type == 'role':
Expand Down Expand Up @@ -525,7 +525,7 @@ def execute_init(self):
if not os.path.exists(b_dir_path):
os.makedirs(b_dir_path)

display.display("- %s was created successfully" % obj_name)
display.display("- %s %s was created successfully" % (galaxy_type.title(), obj_name))

def execute_info(self):
"""
Expand Down
4 changes: 2 additions & 2 deletions test/units/cli/test_galaxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ def test_collection_default(collection_skeleton):
assert metadata['authors'] == ['your name <example@domain.com>']
assert metadata['readme'] == 'README.md'
assert metadata['version'] == '1.0.0'
assert metadata['description'] == 'your description'
assert metadata['description'] == 'your collection description'
assert metadata['license'] == ['GPL-2.0-or-later']
assert metadata['tags'] == []
assert metadata['dependencies'] == {}
Expand Down Expand Up @@ -637,7 +637,7 @@ def test_collection_build(collection_artifact):
assert coll_info['authors'] == ['your name <example@domain.com>']
assert coll_info['readme'] == 'README.md'
assert coll_info['tags'] == []
assert coll_info['description'] == 'your description'
assert coll_info['description'] == 'your collection description'
assert coll_info['license'] == ['GPL-2.0-or-later']
assert coll_info['license_file'] is None
assert coll_info['dependencies'] == {}
Expand Down

0 comments on commit 056aac1

Please sign in to comment.