mirror of
https://github.com/BepInEx/dotnet-runtime.git
synced 2026-11-23 03:39:35 -10:00
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.
24 lines
511 B
Bash
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
|