From 69a087dcfaf65b0049d8247665da425228d6d58b Mon Sep 17 00:00:00 2001 From: meo Date: Tue, 7 Jan 2025 12:12:20 +0100 Subject: [PATCH] fix: remove of db remove the db before testing for more accurate time --- testing.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/testing.sh b/testing.sh index e25bd6c..108e440 100755 --- a/testing.sh +++ b/testing.sh @@ -147,6 +147,7 @@ assertions color_echo "$Green" "Tests passed!" echo "Running rebalancing on big files..." +rm -f rebalance_db.txt # measure time taken start_time=$(date +%s%3N) ./zfs-inplace-rebalancing.sh $test_pool_data_size_path/big >> $log_std_file 2>> $log_error_file @@ -156,7 +157,8 @@ assertions color_echo "$Green" "Tests passed!" echo "Running rebalancing on all files..." -# measure time taken whit +rm -f rebalance_db.txt +# measure time taken start_time=$(date +%s%3N) ./zfs-inplace-rebalancing.sh $test_pool_data_size_path >> $log_std_file 2>> $log_error_file end_time=$(date +%s%3N) @@ -164,5 +166,10 @@ print_time_taken $((end_time - start_time)) assertions color_echo "$Green" "Tests passed!" +color_echo "$Green" "All tests passed!" +color_echo "$Cyan" "Cleaning" +rm -f $log_std_file +rm -f $log_error_file +rm -f rebalance_db.txt +rm -rf $test_pool_data_path -color_echo "$Green" "All tests passed!" \ No newline at end of file