From d06d9dacfe5f557daf02b6814b9a088fbff6f5d4 Mon Sep 17 00:00:00 2001 From: Jonas Bardino Date: Wed, 13 May 2026 12:22:35 +0200 Subject: [PATCH] On some platforms like Ubuntu 26.04 the `pwd` command actually supports the `-h` argument so we need to use a more exotic value to test invalid calls. --- tests/test_mig_shared_safeeval.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_mig_shared_safeeval.py b/tests/test_mig_shared_safeeval.py index 4bec4aa90..3f4fa9c1a 100644 --- a/tests/test_mig_shared_safeeval.py +++ b/tests/test_mig_shared_safeeval.py @@ -3,7 +3,7 @@ # --- BEGIN_HEADER --- # # test_mig_shared_safeeval - unit test of the corresponding mig shared module -# Copyright (C) 2003-2025 The MiG Project by the Science HPC Center at UCPH +# Copyright (C) 2003-2026 The MiG Project by the Science HPC Center at UCPH # # This file is part of MiG. # @@ -49,9 +49,9 @@ def test_subprocess_call(self): def test_subprocess_call_invalid(self): """Check that pwd call with invalid arg fails""" - retval = subprocess_call(['pwd', '-h'], stderr=subprocess_pipe) + retval = subprocess_call(['pwd', '--invalid'], stderr=subprocess_pipe) self.assertNotEqual(retval, 0, - "unexpected subprocess call nosuchcommand retval") + "unexpected subprocess call pwd invalid arg retval") def test_subprocess_check_output(self): """Check that pwd command output matches getcwd as bytes"""