mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-07-03 00:58:53 +00:00
Templar: encapsulate _available_variables (#55435)
Ensure variables are reset between iterations
This commit is contained in:
parent
bd061fd632
commit
34e9d6781b
14 changed files with 47 additions and 30 deletions
|
|
@ -214,7 +214,7 @@ class TestActionBase(unittest.TestCase):
|
|||
self.assertEqual(env_string, "FOO=foo")
|
||||
|
||||
# test environment with a variable in it
|
||||
templar.set_available_variables(variables=dict(the_var='bar'))
|
||||
templar.available_variables = dict(the_var='bar')
|
||||
mock_task.environment = [dict(FOO='{{the_var}}')]
|
||||
env_string = action_base._compute_environment_string()
|
||||
self.assertEqual(env_string, "FOO=bar")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue