diff --git a/images/build-e2e/lib/darwin/run.sh b/images/build-e2e/lib/darwin/run.sh deleted file mode 100755 index 0b417f56bc..0000000000 --- a/images/build-e2e/lib/darwin/run.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/bash - -# Parameters -bundleLocation="" -e2eTagExpression="" -crcMemory="" -targetFolder="crc-e2e" -junitFilename="e2e-junit.xml" -while [[ $# -gt 0 ]]; do - key="$1" - case $key in - -bundleLocation) - bundleLocation="$2" - shift - shift - ;; - -e2eTagExpression) - e2eTagExpression="$2" - shift - shift - ;; - -targetFolder) - targetFolder="$2" - shift - shift - ;; - -junitFilename) - junitFilename="$2" - shift - shift - ;; - -crcMemory) - crcMemory="$2" - shift - shift - ;; - *) # unknown option - shift - ;; - esac -done - -# Prepare resuslts folder -mkdir -p $targetFolder/results - -# Run tests -tags="darwin" -if [ ! -z "$e2eTagExpression" ] -then - tags="$tags && $e2eTagExpression" -fi -cd $targetFolder/bin -./e2e.test --bundle-location=$bundleLocation --pull-secret-file="${HOME}/$targetFolder/pull-secret" --cleanup-home=false --crc-memory=$crcMemory --godog.tags="$tags" --godog.format=junit > "${HOME}/$targetFolder/results/e2e.results" - -# Transform results to junit -cd .. -init_line=$(grep -n '' results/e2e.results | awk '{split($0,n,":"); print n[1]}') -tail -n +$init_line results/e2e.results > results/$junitFilename -# Copy logs and diagnose -cp -r bin/out/test-results/* results \ No newline at end of file diff --git a/images/build-e2e/lib/darwin/run.sh b/images/build-e2e/lib/darwin/run.sh new file mode 120000 index 0000000000..fb5c87c156 --- /dev/null +++ b/images/build-e2e/lib/darwin/run.sh @@ -0,0 +1 @@ +./../linux/run.sh \ No newline at end of file diff --git a/images/build-e2e/lib/linux/run.sh b/images/build-e2e/lib/linux/run.sh index 94fe5737da..f0ef98736d 100755 --- a/images/build-e2e/lib/linux/run.sh +++ b/images/build-e2e/lib/linux/run.sh @@ -34,7 +34,7 @@ while [[ $# -gt 0 ]]; do shift shift ;; - *) # unknown option + *) shift ;; esac @@ -44,7 +44,7 @@ done mkdir -p $targetFolder/results # Run tests -tags="linux" +tags="${OS}" if [ ! -z "$e2eTagExpression" ] then tags="$tags && $e2eTagExpression" diff --git a/images/build-integration/lib/darwin/run.sh b/images/build-integration/lib/darwin/run.sh deleted file mode 100755 index c60ffa12ce..0000000000 --- a/images/build-integration/lib/darwin/run.sh +++ /dev/null @@ -1,63 +0,0 @@ -#!/bin/bash - -# Parameters -bundleLocation="" -targetFolder="crc-integration" -junitFilename="integration-junit.xml" -suiteTimeout="90m" -labelFilter="" -while [[ $# -gt 0 ]]; do - key="$1" - case $key in - -bundleLocation) - bundleLocation="$2" - shift - shift - ;; - -targetFolder) - targetFolder="$2" - shift - shift - ;; - -junitFilename) - junitFilename="$2" - shift - shift - ;; - -suiteTimeout) - suiteTimeout="$2" - shift - shift - ;; - -labelFilter) - labelFilter="$2" - shift - shift - *) # unknown option - shift - ;; - esac -done - -# Prepare resuslts folder -mkdir -p $targetFolder/results - -# Run tests -export PATH="$PATH:${HOME}/$targetFolder/bin" -export PULL_SECRET_PATH="${HOME}/$targetFolder/pull-secret" -if [ ! -z "$bundleLocation" ] -then - export BUNDLE_PATH="$bundleLocation" -fi -cd $targetFolder/bin -if [ ! -z "$labelFilter" ] -then - ./integration.test --ginkgo.timeout $suiteTimeout --ginkgo.label-filter $labelFilter > integration.results -else - ./integration.test --ginkgo.timeout $suiteTimeout > integration.results -fi - -# Copy results -cd .. -cp bin/integration.results results/integration.results -cp bin/out/integration.xml results/$junitFilename \ No newline at end of file diff --git a/images/build-integration/lib/darwin/run.sh b/images/build-integration/lib/darwin/run.sh new file mode 120000 index 0000000000..fb5c87c156 --- /dev/null +++ b/images/build-integration/lib/darwin/run.sh @@ -0,0 +1 @@ +./../linux/run.sh \ No newline at end of file diff --git a/images/build-integration/lib/linux/run.sh b/images/build-integration/lib/linux/run.sh index bb4f5c179f..b50aad597d 100755 --- a/images/build-integration/lib/linux/run.sh +++ b/images/build-integration/lib/linux/run.sh @@ -34,7 +34,7 @@ while [[ $# -gt 0 ]]; do shift shift ;; - *) # unknown option + *) shift ;; esac