Skip to content

Commit

Permalink
fix test_run_shell_cmd_env after changes to env.sh to make unsetting …
Browse files Browse the repository at this point in the history
…of environment more robust
  • Loading branch information
boegel committed Oct 16, 2024
1 parent ee9f6ce commit 46102d3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/framework/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,8 @@ def test_run_shell_cmd_env(self):
env_script = os.path.join(cmd_tmpdir, 'env.sh')
self.assertExists(env_script)
env_script_txt = read_file(env_script)
self.assertTrue(env_script_txt.startswith('unset -f $('))
self.assertIn('unset "$var"', env_script_txt)
self.assertIn('unset -f "$func"', env_script_txt)
self.assertIn('\nexport FOOBAR=foobar\nexport PATH', env_script_txt)

cmd_script = os.path.join(cmd_tmpdir, 'cmd.sh')
Expand Down

0 comments on commit 46102d3

Please sign in to comment.