forked from dotnet/macios
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathlaunch-manual-sample-tests.sh
executable file
·28 lines (23 loc) · 1.09 KB
/
launch-manual-sample-tests.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/bash -ex
# This script will schedule a manual sample test run for the current commit.
# The current commit must already have packages available as GitHub statuses.
# An Azure Personal Access Token with Build/Read&Execute rights must be stored in ~/.local/share/Xamarin/.vsts-pat
HASH="$(git log -1 --pretty=format:%H)"
GIT_BRANCH=$(git rev-parse --abbrev-ref HEAD)
GH_MANIFEST=$(curl https://bosstoragemirror.blob.core.windows.net/wrench/jenkins/"$HASH"/package/manifest)
IOS_PACKAGE_URL=$(echo "$GH_MANIFEST" | grep "xamarin.ios.*pkg$")
MAC_PACKAGE_URL=$(echo "$GH_MANIFEST" | grep "xamarin.mac.*pkg$")
if test -z "$IOS_PACKAGE_URL"; then
echo "No Xamarin.iOS package found."
exit 1
elif test -z "$MAC_PACKAGE_URL"; then
echo "No Xamarin.Mac package found."
exit 1
fi
make -C "$(git rev-parse --show-toplevel)/../maccore/tests/external" wrench-launch-sample-builds \
BUILD_BRANCH="$GIT_BRANCH" \
BUILD_REVISION="$HASH" \
BUILD_WORK_HOST=jenkins \
WRENCH_URL=https://github.com/xamarin/xamarin-macios/commit/"$HASH" \
MAC_PACKAGE_URL="$MAC_PACKAGE_URL" \
IOS_PACKAGE_URL="$IOS_PACKAGE_URL" \