From b81d9bf18cd99b60f4bd964f190f63673e0a9b6b Mon Sep 17 00:00:00 2001 From: Siri Hansen Date: Mon, 3 Jun 2013 17:47:34 +0200 Subject: [sasl] Remove priv dir after release_handler_SUITE Since introducing unicode paths, the name of the priv_dir will include "unicode characters" and on some platforms (e.g. Windows) these are not so easily removed by the daily cleanup scripts. To avoid lingering directories, the priv_dir is now completly removed by the suite itself (unless there are failed testcases and logs must be saved). --- lib/sasl/test/release_handler_SUITE.erl | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'lib/sasl/test') diff --git a/lib/sasl/test/release_handler_SUITE.erl b/lib/sasl/test/release_handler_SUITE.erl index 816dc7b36c..b73691310f 100644 --- a/lib/sasl/test/release_handler_SUITE.erl +++ b/lib/sasl/test/release_handler_SUITE.erl @@ -35,7 +35,8 @@ init_per_suite(Config) -> application:start(sasl), Config. -end_per_suite(_Config) -> +end_per_suite(Config) -> + clean_priv_dir(Config,true), ok. all() -> @@ -163,7 +164,6 @@ end_per_group(release, Config) -> {win32,_} -> delete_all_services(); _ -> ok end, - clean_priv_dir(Config,true), ?t:timetrap_cancel(Dog), Config; end_per_group(_GroupName, Config) -> @@ -1962,7 +1962,11 @@ copy_client(Conf,Master,Sname,Client) -> clean_priv_dir(Conf,Save) -> PrivDir = priv_dir(Conf), - rh_test_lib:clean_dir(PrivDir,Save). + rh_test_lib:clean_dir(PrivDir,Save), + case file:list_dir(PrivDir) of + {ok,[]} -> _ = file:del_dir(PrivDir); + _ -> ok + end. node_name(Sname) when is_atom(Sname) -> {ok,Host} = inet:gethostname(), -- cgit v1.2.3