From 6f39a9ba291db640ec5171fb9a14b1ff7c69d186 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Thu, 18 Jun 2026 14:48:20 +0200 Subject: [PATCH] support/testing: test_which.py: use assertRunNotOk() Use the helper to simplify the test. Signed-off-by: Peter Korsgaard --- support/testing/tests/package/test_which.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/support/testing/tests/package/test_which.py b/support/testing/tests/package/test_which.py index 38f528aa7f..05ed56ccb4 100644 --- a/support/testing/tests/package/test_which.py +++ b/support/testing/tests/package/test_which.py @@ -33,8 +33,7 @@ class TestWhich(infra.basetest.BRTest): # We check "which" returns an error when the program is not # found. - _, ret = self.emulator.run(f"which {alias_name}") - self.assertNotEqual(ret, 0) + self.assertRunNotOk(f"which {alias_name}") # We define a shell alias. alias_cmd = "/bin/true"