Files
dotnet-runtime/eng/testing/AndroidRunnerTemplate.sh
T
Santiago Fernandez Madero 210a82a2e7 Build tests as self contained apps for mobile targets (#36262)
This uses the SDK to publish tests as self contained apps before building the app bundle using the built runtime pack. 

I moved the `RunTests.sh` output path to `BundleDir` as whenever we start sending to helix, there is no need to .zip up the whole `OutDir` as we can just send the bundle + `RunTests.sh` script.
2020-05-12 13:47:59 +02:00

24 lines
511 B
Bash

#!/usr/bin/env bash
EXECUTION_DIR=$(dirname $0)
TEST_NAME=$1
TARGET_ARCH=$2
APK=$EXECUTION_DIR/bin/$TEST_NAME.apk
# it doesn't support parallel execution yet, so, here is a hand-made semaphore:
LOCKDIR=/tmp/androidtests.lock
while true; do
if mkdir "$LOCKDIR"
then
trap 'rm -rf "$LOCKDIR"' 0
break
else
sleep 5
fi
done
dotnet xharness android test -i="net.dot.MonoRunner" \
--package-name="net.dot.$TEST_NAME" \
--app=$APK -o=$EXECUTION_DIR/TestResults -v