* [PATCH 1/2] test-runner: catch exception on test file removal
@ 2021-12-23 1:12 James Prestwood
0 siblings, 0 replies; 2+ messages in thread
From: James Prestwood @ 2021-12-23 1:12 UTC (permalink / raw)
To: iwd
[-- Attachment #1: Type: text/plain, Size: 734 bytes --]
Without catching this can result in a fatal error, ending the
test run.
---
tools/test-runner | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tools/test-runner b/tools/test-runner
index 7fa8b840..b5c4f777 100755
--- a/tools/test-runner
+++ b/tools/test-runner
@@ -1380,7 +1380,10 @@ def post_test(ctx, to_copy):
allowed = ['phonesim.conf', 'certs', 'secrets', 'iwd']
for f in [f for f in os.listdir('/tmp') if f not in allowed]:
dbg("File %s was not cleaned up!" % f)
- os.remove('/tmp/' + f)
+ try:
+ os.remove('/tmp/' + f)
+ except:
+ pass
def print_results(results):
table = PrettyTable(['Test', colored('Passed', 'green'), colored('Failed', 'red'), \
--
2.31.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/2] test-runner: catch exception on test file removal
@ 2021-12-23 1:16 Denis Kenzior
0 siblings, 0 replies; 2+ messages in thread
From: Denis Kenzior @ 2021-12-23 1:16 UTC (permalink / raw)
To: iwd
[-- Attachment #1: Type: text/plain, Size: 275 bytes --]
Hi James,
On 12/22/21 19:12, James Prestwood wrote:
> Without catching this can result in a fatal error, ending the
> test run.
> ---
> tools/test-runner | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
Both applied, thanks.
Regards,
-Denis
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-12-23 1:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-23 1:12 [PATCH 1/2] test-runner: catch exception on test file removal James Prestwood
-- strict thread matches above, loose matches on Subject: below --
2021-12-23 1:16 Denis Kenzior
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox