-
Notifications
You must be signed in to change notification settings - Fork 35
/
azure-pipelines.yml
111 lines (96 loc) · 2.95 KB
/
azure-pipelines.yml
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
variables:
# When Agent.JobName matches this value (and the git ref is a tag), then
# built artifacts will be published to Azure Blob Storage.
- name: "AzurePublishWhen"
value: "Mojave-Xcode-11.1"
- group: "XamarinUITestCI"
trigger:
tags:
include:
- '*'
branches:
include:
- master
pr:
branches:
include:
- master
schedules:
- cron: "0 1 * * Mon-Fri"
displayName: Nightly build
branches:
include:
- master
always: true
jobs:
- job:
strategy:
matrix:
Mojave-Xcode-10.3:
IMAGE_POOL: 'macOS-10.14'
XCODE_VERSION: '10.3'
Mojave-Xcode-11.0:
IMAGE_POOL: 'macOS-10.14'
XCODE_VERSION: '11'
Mojave-Xcode-11.1:
IMAGE_POOL: 'macOS-10.14'
XCODE_VERSION: '11.1'
Mojave-Xcode-11.2:
IMAGE_POOL: 'macOS-10.14'
XCODE_VERSION: '11.2'
pool:
vmImage: $(IMAGE_POOL)
timeoutInMinutes: 120
steps:
- script: |
set -e
sudo xcode-select --switch "/Applications/Xcode_$(XCODE_VERSION).app/Contents/Developer"
displayName: "$(IMAGE_POOL) - Xcode $(XCODE_VERSION)"
- script: |
set -e
ruby -v
bundler -v
displayName: "Ruby info"
- script: gem install bundler -v 1.17.3
displayName: "Install bundler 1.17.3"
- script: |
set -e
echo -e "install: --no-document --env-shebang\nupdate: --no-document --env-shebang" > ~/.gemrc
bundle install
displayName: "Bundle install"
- script: |
set -e
git clone https://$(CalabashKeychainGitHubAccessToken)@github.com/xamarinhq/calabash-codesign.git
calabash-codesign/apple/create-keychain.sh
displayName: "Download and install keychain"
- script: bundle _1.17.3_ install
workingDirectory: 'CalSmokeApp'
displayName: "CalSmokeApp bundle install"
- script: make app-cal
workingDirectory: 'CalSmokeApp'
displayName: "Make app-cal"
- script: make ipa-cal
workingDirectory: 'CalSmokeApp'
displayName: "Make ipa-cal"
- script: SKIP_IPA_BUILD=1 bin/appcenter.sh App-Center-Test-Cloud/daily-ios
workingDirectory: 'CalSmokeApp'
displayName: "Appcenter tests"
- script: bundle exec bin/ci/cucumber.rb
displayName: "Cucumber tests"
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFiles: 'CalSmokeApp/reports/**/*.xml'
failTaskOnFailedTests: true
condition: always()
- task: Bash@3
inputs:
targetType: filePath
filePath: "./bin/ci/az-publish.sh"
env:
AZURE_STORAGE_ACCOUNT: $(AzureStorageAccount)
AZURE_STORAGE_KEY: $(AzureStorageKey)
AZURE_STORAGE_CONNECTION_STRING: $(AzureStorageConnectionString)
SOURCE_BRANCH: $(Build.SourceBranch)
displayName: "Publish to Azure Blob Storage"
condition: and(succeeded(), eq(variables['Agent.JobName'], variables['AzurePublishWhen']), eq(variables['Build.SourceBranch'], 'refs/heads/master'), eq(variables['Build.Reason'], 'IndividualCI'))