Skip to content

Commit

Permalink
Correctly assert raises
Browse files Browse the repository at this point in the history
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
  • Loading branch information
JeanChristopheMorinPerso committed Jul 21, 2024
1 parent 20d7ec2 commit ee2658b
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/rez/tests/test_utils_elf.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,8 @@ def tearDownClass(cls):
@program_dependent("readelf")
def test_get_rpaths_raises_runtime_exception(self):
"""Tests that no TypeError from elf functions are raised."""
self.assertRaises(
RuntimeError,
with self.assertRaises(RuntimeError):
get_rpaths("/path/to/elfpath")
)

self.assertRaises(
RuntimeError,
with self.assertRaises(RuntimeError):
patch_rpaths("/path/to/elfpath", ["$ORIGIN", "$ORIGINTEST"])
)

0 comments on commit ee2658b

Please sign in to comment.