From 3c0e931b553d0c633e65a6dc36cf5aab0a544753 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Wed, 17 Jan 2018 14:08:17 +0100 Subject: Improve recursive 'source' test Check for incorrect exceptions instead of propagating them, and get rid of the flag. --- testsuite.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/testsuite.py b/testsuite.py index a876f0e..dcc5607 100644 --- a/testsuite.py +++ b/testsuite.py @@ -781,15 +781,14 @@ g # Test recursive 'source' detection - got_syntax_exception = False try: Kconfig("Kconfiglib/tests/Krecursive1") except KconfigSyntaxError: - got_syntax_exception = True - - verify(got_syntax_exception, - "recursive 'source' did not raise KconfigSyntaxError") - + pass + except: + fail("recursive 'source' raised wrong exception") + else: + fail("recursive 'source' did not raise exception") print("Testing visibility") -- cgit v1.2.3