Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Nattress <nattress@gmail.com>2017-01-21 00:44:53 +0300
committerSimon Nattress <nattress@gmail.com>2017-01-21 00:44:53 +0300
commit14e3ad3e69a77f925fd4d40b52be42c622eabcf3 (patch)
tree445b47caa470b6645be88b944a0f9c379775095f
parentf7061a317a0f4b206f76c034e30a28deddb64992 (diff)
Emit correct log file name
Rename test results log to `testResults.xml` to be picked up by CI. Place log file under bin/Logs so it’s in a standard place for this repo.
-rwxr-xr-xtests/CoreCLR/runtest/runtest.sh10
-rwxr-xr-xtests/runtest.sh18
2 files changed, 20 insertions, 8 deletions
diff --git a/tests/CoreCLR/runtest/runtest.sh b/tests/CoreCLR/runtest/runtest.sh
index 5b4072704..6e227ee42 100755
--- a/tests/CoreCLR/runtest/runtest.sh
+++ b/tests/CoreCLR/runtest/runtest.sh
@@ -61,6 +61,7 @@ function print_usage {
echo ' --build-overlay-only : Exit after overlay directory is populated'
echo ' --limitedDumpGeneration : Enables the generation of a limited number of core dumps if test(s) crash, even if ulimit'
echo ' is zero when launching this script. This option is intended for use in CI.'
+ echo ' --logdir=<log folder> : Specifies a folder to emit logs to. Default is test root folder.'
echo ''
echo 'Runtime Code Coverage options:'
echo ' --coreclr-coverage : Optional argument to get coreclr code coverage reports'
@@ -126,7 +127,7 @@ fi
find . -type f -name "local_dumplings.txt" -exec rm {} \;
function xunit_output_begin {
- xunitOutputPath=$testRootDir/coreclrtests.xml
+ xunitOutputPath=$__LogDir/testResults.xml
xunitTestOutputPath=${xunitOutputPath}.test
if [ -e "$xunitOutputPath" ]; then
rm -f -r "$xunitOutputPath"
@@ -1082,6 +1083,9 @@ do
--limitedDumpGeneration)
limitedCoreDumps=ON
;;
+ --logdir=*)
+ __LogDir=${i#*=}
+ ;;
*)
echo "Unknown switch: $i"
print_usage
@@ -1111,6 +1115,10 @@ if [ ! -d "$testRootDir" ]; then
exit $EXIT_CODE_EXCEPTION
fi
+if [ -z "$__LogDir" ]; then
+ __LogDir=$testRootDir
+fi
+
# Copy native interop test libraries over to the mscorlib path in
# order for interop tests to run on linux.
if [ -z "$mscorlibDir" ]; then
diff --git a/tests/runtest.sh b/tests/runtest.sh
index ce7e7ab4a..09a44946f 100755
--- a/tests/runtest.sh
+++ b/tests/runtest.sh
@@ -112,8 +112,8 @@ run_coreclr_tests()
CoreRT_TestSelectionArg=
fi
- echo ./runtest.sh --testRootDir=${CoreRT_TestExtRepo} --coreOverlayDir=${CoreRT_TestRoot}/CoreCLR ${CoreRT_TestSelectionArg}
- ./runtest.sh --testRootDir=${CoreRT_TestExtRepo} --coreOverlayDir=${CoreRT_TestRoot}/CoreCLR ${CoreRT_TestSelectionArg}
+ echo ./runtest.sh --testRootDir=${CoreRT_TestExtRepo} --coreOverlayDir=${CoreRT_TestRoot}/CoreCLR ${CoreRT_TestSelectionArg} --logdir=$__LogDir
+ ./runtest.sh --testRootDir=${CoreRT_TestExtRepo} --coreOverlayDir=${CoreRT_TestRoot}/CoreCLR ${CoreRT_TestSelectionArg} --logdir=$__LogDir
}
CoreRT_TestRoot="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
@@ -180,21 +180,25 @@ done
source "$CoreRT_TestRoot/testenv.sh"
-if [ ${CoreRT_RunCoreCLRTests} ]; then
- run_coreclr_tests
- exit $?
-fi
-
__BuildStr=${CoreRT_BuildOS}.${CoreRT_BuildArch}.${CoreRT_BuildType}
__CoreRTTestBinDir=${CoreRT_TestRoot}/../bin/tests
__LogDir=${CoreRT_TestRoot}/../bin/Logs/${__BuildStr}/tests
__build_os_lowcase=$(echo "${CoreRT_BuildOS}" | tr '[:upper:]' '[:lower:]')
+if [ ! -d $__LogDir ]; then
+ mkdir -p $__LogDir
+fi
+
if [ ! -d ${CoreRT_ToolchainDir} ]; then
echo "Toolchain not found in ${CoreRT_ToolchainDir}"
exit -1
fi
+if [ ${CoreRT_RunCoreCLRTests} ]; then
+ run_coreclr_tests
+ exit $?
+fi
+
__CppTotalTests=0
__CppPassedTests=0
__JitTotalTests=0