use -f instead of /dev/null in the tests

This commit is contained in:
Björn Grüning
2022-05-13 16:18:58 +02:00
committed by GitHub
parent 2f52e36d11
commit 4e8819e793
+1 -1
View File
@@ -54,7 +54,7 @@ class TestCommandFactory(TestCase):
self.job_wrapper.command_line = f"{TRAP_KILL_CONTAINER}{MOCK_COMMAND_LINE}"
expected_command_line = self._surround_command(MOCK_COMMAND_LINE).replace(
"""trap 'rm "$__out" "$__err"' EXIT""",
"""trap 'rm "$__out" "$__err" 2> /dev/null || true; _on_exit' EXIT"""
"""trap 'rm -f "$__out" "$__err"; _on_exit' EXIT"""
)
self.__assert_command_is(expected_command_line)