This commit is contained in:
Alexander Chocron 2017-11-15 14:38:59 -08:00
Родитель 27bd1dcb92
Коммит d6201fcea4
3 изменённых файлов: 10 добавлений и 10 удалений

Просмотреть файл

@ -11,11 +11,11 @@ if [ $? -ne 0 ]; then
fi
# Is App Center CLI installed?
npm list -g mobile-center-cli >/dev/null
npm list -g appcenter-cli >/dev/null
if [ $? -ne 0 ]; then
# Install App Center CLI
echo "Installing App Center CLI..."
npm install -g mobile-center-cli
npm install -g appcenter-cli
if [ $? -ne 0 ]; then
echo "An error occured while installing App Center CLI."
exit 1
@ -24,7 +24,7 @@ fi
# Log in to App Center
echo "Logging in to App Center..."
mobile-center login --token "$APP_CENTER_API_TOKEN"
appcenter login --token "$APP_CENTER_API_TOKEN"
if [ $? -ne 0 ]; then
echo "An error occured while logging into App Center."
exit 1

Просмотреть файл

@ -17,8 +17,8 @@ ANDROID_APP_NAME="appcenter-xamarin-testing-app-android"
IOS_APP_NAME="appcenter-xamarin-testing-app-ios"
ANDROID_APP="$APP_CENTER_USERNAME/$ANDROID_APP_NAME"
IOS_APP="$APP_CENTER_USERNAME/$IOS_APP_NAME"
ANDROID_PORTAL_URL="https://mobile.azure.com/users/$APP_CENTER_USERNAME/apps/$ANDROID_APP_NAME/test/runs/"
IOS_PORTAL_URL="https://mobile.azure.com/users/$APP_CENTER_USERNAME/apps/$IOS_APP_NAME/test/runs/"
ANDROID_PORTAL_URL="https://appcenter.ms/users/$APP_CENTER_USERNAME/apps/$ANDROID_APP_NAME/test/runs/"
IOS_PORTAL_URL="https://appcenter.ms/users/$APP_CENTER_USERNAME/apps/$IOS_APP_NAME/test/runs/"
# Text attribute constants
RED=$(tput setaf 1)
@ -68,7 +68,7 @@ test_status() {
TEST_STATUS_DONE_TEXT="Current test status: Done"
RESULTS_FILE="results_file.txt"
TEST_DONE=0
mobile-center test status --test-run-id $TEST_RUN_ID --app "$APP_NAME" > $RESULTS_FILE
appcenter test status --test-run-id $TEST_RUN_ID --app "$APP_NAME" > $RESULTS_FILE
RETURN_CODE=$?
if grep -q "$TEST_STATUS_DONE_TEXT" "$RESULTS_FILE"; then
TEST_DONE=1
@ -87,7 +87,7 @@ test_status() {
}
# Log in to App Center
./mobile-center-login.sh
./appcenter-login.sh
if [ $? -ne 0 ]; then
exit 1
fi

Просмотреть файл

@ -40,8 +40,8 @@ IOS_APP="$APP_CENTER_USERNAME/$IOS_APP_NAME"
TEST_SERIES="master"
# Define results constants
ANDROID_PORTAL_URL="https://mobile.azure.com/users/$APP_CENTER_USERNAME/apps/$ANDROID_APP_NAME/test/runs/"
IOS_PORTAL_URL="https://mobile.azure.com/users/$APP_CENTER_USERNAME/apps/$IOS_APP_NAME/test/runs/"
ANDROID_PORTAL_URL="https://appcenter.ms/users/$APP_CENTER_USERNAME/apps/$ANDROID_APP_NAME/test/runs/"
IOS_PORTAL_URL="https://appcenter.ms/users/$APP_CENTER_USERNAME/apps/$IOS_APP_NAME/test/runs/"
ANDROID_INFORMATION_FILE="android_info.txt"
IOS_INFORMATION_FILE="ios_info.txt"
ANDROID_PLATFORM_NAME="Android"
@ -95,7 +95,7 @@ initialize_tests() {
DEVICES_CODE="$2"
APP_PACKAGE="$3"
INFORMATION_FILE="$4"
mobile-center test run uitest --app $APP_NAME\
appcenter test run uitest --app $APP_NAME\
--devices $DEVICES_CODE --app-path $APP_PACKAGE\
--test-series $TEST_SERIES --locale $LOCALE\
--build-dir $UITEST_BUILD_DIR --async true > $INFORMATION_FILE