From 4f330fdcb0bfee6372584b28a098a14bc7803c5c Mon Sep 17 00:00:00 2001 From: Geunsik Lim Date: Fri, 20 May 2016 22:31:32 +0900 Subject: [PATCH] Linux/ARM: Add execution time of ./tests/runtest.sh We have to wait for a long time to complete all unit tests on the ARM-based embedded boards (e.g, Raspberry Pi, Odroid, Chromebook) compared to the X86-based server environment. So, let's display execution time after finishing the unit test. * After PR: 128 minutes and 36 seconds taken to run CoreCLR tests. ver1: The existing measured time still includes overlay creation and some package restoration. So, let's put time_start in front of if($testDirectories). Signed-off-by: Geunsik Lim Reviewed-by: Aditya Mandaleeka Reviewed-by: Sergiy Kuryata --- tests/runtest.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/runtest.sh b/tests/runtest.sh index 26500fc..64a3535 100755 --- a/tests/runtest.sh +++ b/tests/runtest.sh @@ -899,6 +899,7 @@ scriptPath=$(dirname $0) ${scriptPath}/setup-runtime-dependencies.sh --outputDir=$coreOverlayDir cd "$testRootDir" +time_start=$(date +"%s") if [ -z "$testDirectories" ] then # No test directories were specified, so run everything in the current @@ -918,6 +919,11 @@ fi finish_remaining_tests print_results + +time_end=$(date +"%s") +time_diff=$(($time_end-$time_start)) +echo "$(($time_diff / 60)) minutes and $(($time_diff % 60)) seconds taken to run CoreCLR tests." + xunit_output_end if [ "$CoreClrCoverage" == "ON" ] -- 2.7.4