From c53a8500e7b693a2edc785df19698720314f3dfb Mon Sep 17 00:00:00 2001 From: Matthias Wachs Date: Mon, 8 Apr 2013 09:47:11 +0000 Subject: fix --- ...tion_bootstrap_and_connect_and_disconnect.py.in | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/src/integration-tests/test_integration_bootstrap_and_connect_and_disconnect.py.in b/src/integration-tests/test_integration_bootstrap_and_connect_and_disconnect.py.in index 3ca0aea86..49e425932 100755 --- a/src/integration-tests/test_integration_bootstrap_and_connect_and_disconnect.py.in +++ b/src/integration-tests/test_integration_bootstrap_and_connect_and_disconnect.py.in @@ -57,8 +57,26 @@ else: tmp = "/tmp" def cleanup (): - shutil.rmtree (os.path.join (tmp, "c_bootstrap_server"), True) - shutil.rmtree (os.path.join (tmp, "c_no_nat_client"), True) + retries = 10 + path = os.path.join (tmp, "c_bootstrap_server") + test.p ("Removing " + path) + while ((os.path.exists(path)) and (retries > 0)): + shutil.rmtree ((path), False) + time.sleep (1) + retries -= 1 + if (os.path.exists(path)): + test.p ("Failed to remove " + path) + + + retries = 10 + path = os.path.join (tmp, "c_no_nat_client") + test.p ("Removing " + path) + while ((os.path.exists(path)) and (retries > 0)): + shutil.rmtree ((path), False) + time.sleep (1) + retries -= 1 + if (os.path.exists(path)): + test.p ("Failed to remove " + path) def success_server_stop_cont (check): global success -- cgit v1.2.3