Skip to content

Commit 7e4b9d4

Browse files
committed
Use assertRaises
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
1 parent 8a70bcb commit 7e4b9d4

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

bpython/test/test_args.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,5 @@ def test_exec_dunder_file(self):
3939
class TestParse(TestCase):
4040

4141
def test_version(self):
42-
try:
42+
with self.assertRaises(SystemExit):
4343
args.parse(['--version'])
44-
except SystemExit:
45-
pass
46-
else:
47-
self.fail('Should have raise SystemExit')

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy