Skip to content

Commit b3522fe

Browse files
authored
Merge pull request #2855 from bridadan/handle-exceptions-better
[Tools] Handling Exceptions better when building tests
2 parents dd54f7b + cadcc80 commit b3522fe

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

tools/test_api.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2102,14 +2102,14 @@ def build_tests(tests, base_source_paths, build_path, target, toolchain_name,
21022102
app_config=app_config,
21032103
build_profile=build_profile)
21042104

2105-
except Exception, e:
2106-
if not isinstance(e, NotSupportedException):
2107-
result = False
2108-
2109-
if continue_on_build_fail:
2110-
continue
2111-
else:
2112-
break
2105+
except NotSupportedException:
2106+
pass
2107+
except ToolException:
2108+
result = False
2109+
if continue_on_build_fail:
2110+
continue
2111+
else:
2112+
break
21132113

21142114
# If a clean build was carried out last time, disable it for the next build.
21152115
# Otherwise the previously built test will be deleted.

0 commit comments

Comments
 (0)