diff options
author | Peter Lemenkov <[email protected]> | 2014-12-02 13:31:37 +0300 |
---|---|---|
committer | Peter Lemenkov <[email protected]> | 2014-12-15 21:05:05 +0300 |
commit | bb7fb3c31d1939ab39fb14322d11a59bc34d8f42 (patch) | |
tree | b3a37d800ac7d073723cd5cc02da09839e2b79e8 /lib/common_test | |
parent | 5cbad390e971ff92a7fb1b71757041ff9edeb81a (diff) | |
download | otp-bb7fb3c31d1939ab39fb14322d11a59bc34d8f42.tar.gz otp-bb7fb3c31d1939ab39fb14322d11a59bc34d8f42.tar.bz2 otp-bb7fb3c31d1939ab39fb14322d11a59bc34d8f42.zip |
Start using os:getenv/2 fun
See #535
Signed-off-by: Peter Lemenkov <[email protected]>
Diffstat (limited to 'lib/common_test')
-rw-r--r-- | lib/common_test/test/ct_test_support.erl | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/common_test/test/ct_test_support.erl b/lib/common_test/test/ct_test_support.erl index 746469584d..2c1f98d63b 100644 --- a/lib/common_test/test/ct_test_support.erl +++ b/lib/common_test/test/ct_test_support.erl @@ -1340,12 +1340,7 @@ delete_old_logs(_, Config) -> delete_dirs(LogDir) -> Now = calendar:datetime_to_gregorian_seconds(calendar:local_time()), - SaveTime = case os:getenv("CT_SAVE_OLD_LOGS") of - false -> - 28800; - SaveTime0 -> - list_to_integer(SaveTime0) - end, + SaveTime = list_to_integer(os:getenv("CT_SAVE_OLD_LOGS", "28800")), Deadline = Now - SaveTime, Dirs = filelib:wildcard(filename:join(LogDir,"ct_run*")), Dirs2Del = |