support/testing: test_lsof.py: use assertRunNotOk()

Use the helper to simplify the test.

Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
(cherry picked from commit aae70a3ab5)
Signed-off-by: Thomas Perale <thomas.perale@mind.be>
This commit is contained in:
Peter Korsgaard
2026-06-18 14:48:08 +02:00
committed by Thomas Perale
parent e430365223
commit 64f5559e11

View File

@@ -28,8 +28,7 @@ class TestLsof(infra.basetest.BRTest):
self.assertRunOk("lsof")
# Check lsof fails if requested file is not opened
_, exit_code = self.emulator.run("lsof {}".format(test_file))
self.assertNotEqual(exit_code, 0)
self.assertRunNotOk("lsof {}".format(test_file))
# Open the test file from the shell on descriptor 10
self.assertRunOk("exec 10> {}".format(test_file))