aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pmstestsuite/library/standard/banned_commands.py9
1 files changed, 3 insertions, 6 deletions
diff --git a/pmstestsuite/library/standard/banned_commands.py b/pmstestsuite/library/standard/banned_commands.py
index 7e3de17..5ddc80f 100644
--- a/pmstestsuite/library/standard/banned_commands.py
+++ b/pmstestsuite/library/standard/banned_commands.py
@@ -36,12 +36,12 @@ class DoHardCommandTest(BannedCommandTest):
except IndexError:
res = None
+ exc = None
if self.eapi < 4:
try:
self.assertTrue(res, 'hardlink created')
except AssertionError as e:
- if exc is None:
- exc = e
+ exc = e
try:
self.assertTrue(output[1] == '0', 'hardlink preserved after merge',
undefined = True)
@@ -76,9 +76,6 @@ class DoSedCommandTest(BannedCommandTest):
if self.eapi < 4:
self.assertEqual(res, 'SED WORKED', 'dosed result')
- elif res is not None or exc:
+ elif res is not None:
self.assertNotEqual(res, 'SED WORKED', 'dosed result',
undefined = True)
-
- if exc:
- raise exc