mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-28 03:00:23 -07:00
Merge pull request #3082 from pol/devel
Handle '#' in var strings by splitting on ' #'
This commit is contained in:
commit
ee6ea97435
3 changed files with 4 additions and 4 deletions
|
@ -302,4 +302,4 @@ class TestInventory(unittest.TestCase):
|
||||||
assert vars == {'inventory_hostname': 'zeus',
|
assert vars == {'inventory_hostname': 'zeus',
|
||||||
'inventory_hostname_short': 'zeus',
|
'inventory_hostname_short': 'zeus',
|
||||||
'group_names': ['greek', 'major-god', 'ungrouped'],
|
'group_names': ['greek', 'major-god', 'ungrouped'],
|
||||||
'var_a': '1'}
|
'var_a': '1#2'}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
[major-god] # group with inline comments
|
[major-god] # group with inline comments
|
||||||
zeus var_a=1 # host with inline comments
|
zeus var_a="1#2" # host with inline comments and "#" in the var string
|
||||||
# A comment
|
# A comment
|
||||||
thor
|
thor
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue