-
Notifications
You must be signed in to change notification settings - Fork 12
/
step.yml
executable file
·199 lines (182 loc) · 13.6 KB
/
step.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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
title: "iOS Device Testing"
summary: Run iOS XCUItests on devices
description: |-
Run iOS XCUItests on physical devices with Google's Firebase Test Lab. You do not have to set up and register your own devices and you don't need your own Firebase account.
We'll go over the most important configuration information for the Step. For more information, check out our [detailed guide](https://devcenter.bitrise.io/en/testing/device-testing-for-ios.html).
### Configuring the Step
To use the Step, you need to build an IPA file with Xcode's `build-for-testing` action. You can use our dedicated Step:
1. Add the **Xcode Build for testing for iOS** Step to your Workflow.
The Step exports a .zip file that contains your test directory (by default, it’s `Debug-iphoneos`) and the xctestrun file.
1. Add the **iOS Device Testing** Step to the Workflow.
1. In the **Test devices** input field, specify the devices on which you want to test the app.
1. Optionally, you can set a test timeout and configure file download in the **Debug** input group. The path to the downloaded files will be exported as an Environment Variable and it can be used by subsequent Steps.
1. Make sure you have the **Deploy to Bitrise.io** Step in your Workflow, with version 1.4.1 or newer. With the older versions of the Step, you won’t be able to check your results on the Test Reports page!
Please note you should not change the value of the **API token** and the **Test API's base URL** input.
### Troubleshooting
If you get the **Build already exists** error, it is because you have more than one instance of the Step in your Workflow. This doesn't work as Bitrise sends the build slug to Firebase and having the Step more than once in the same Workflow results in sending the same build slug multiple times.
### Useful links
[Device testing for iOS](https://devcenter.bitrise.io/en/testing/device-testing-for-ios.html)
### Related Steps
[Xcode Build for testing for iOS](https://www.bitrise.io/integrations/steps/xcode-build-for-test)
[Xcode Test for iOS](https://www.bitrise.io/integrations/steps/xcode-test)
website: https://github.com/bitrise-steplib/steps-virtual-device-testing-for-ios
source_code_url: https://github.com/bitrise-steplib/steps-virtual-device-testing-for-ios
support_url: https://github.com/bitrise-steplib/steps-virtual-device-testing-for-ios/issues
project_type_tags:
- ios
- cordova
- ionic
- react-native
- flutter
type_tags:
- test
is_always_run: false
is_skippable: false
run_if: ".IsCI"
meta:
bitrise.io:
addons_required:
- addons-testing
toolkit:
go:
package_name: github.com/bitrise-steplib/steps-virtual-device-testing-for-ios
inputs:
- zip_path: $BITRISE_TEST_BUNDLE_ZIP_PATH
opts:
title: "Zip path"
summary: |
The path to the zip file which contains the folder Debug-iphoneos and PROJECT_NAME_iphoneos_DEVELOPMENT_TARGET-arm64.xctestrun.
description: |
Open finder, and navigate to the directory you designated for Derived Data output.
Open the folder for your project, then the Build/Products folders inside it.
You should see a folder Debug-iphoneos and PROJECT_NAME_iphoneos_DEVELOPMENT_TARGET-arm64.xctestrun. Select them both, then right-click on one of them and select Compress 2 items.
is_required: true
- test_devices: "iphone8,14.7,en,portrait"
opts:
title: "Test devices"
description: |
Format:
One device configuration per line and the parameters are separated with `,` in the order of: `deviceID,version,language,orientation`
For example:
`iphone8,14.7,en,portrait`
`iphone8,14.7,en,landscape`
Available devices and its versions:
```
┌─────────────┬───────────────────────┬─────────────────────┬─────────────────────────────────┐
│ MODEL_ID │ NAME │ OS_VERSION_IDS │ TAGS │
├─────────────┼───────────────────────┼─────────────────────┼─────────────────────────────────┤
│ ipad5 │ iPad (5th generation) │ 15.4 │ reduced_stability=15.4 │
│ ipadmini4 │ iPad mini 4 │ 15.4 │ │
│ iphone11pro │ iPhone 11 Pro │ 14.7,16.5,16.6 │ deprecated=16.5 │
│ iphone12pro │ iPhone 12 Pro │ 14.8 │ │
│ iphone13pro │ iPhone 13 Pro │ 15.2,15.7 │ reduced_stability=15.2, default │
│ iphone14pro │ iPhone 14 Pro │ 16.5,16.6 │ deprecated=16.5 │
│ iphone8 │ iPhone 8 │ 14.7,15.7,16.5,16.6 │ deprecated=16.5 │
└─────────────┴───────────────────────┴─────────────────────┴─────────────────────────────────┘
```
Device and OS Capacity:
```
┌─────────────┬───────────────────────┬───────────────┬─────────────────┐
│ MODEL_ID │ MODEL_NAME │ OS_VERSION_ID │ DEVICE_CAPACITY │
├─────────────┼───────────────────────┼───────────────┼─────────────────┤
│ ipad5 │ iPad (5th generation) │ 15.4 │ Low │
│ ipadmini4 │ iPad mini 4 │ 15.4 │ Low │
│ iphone11pro │ iPhone 11 Pro │ 14.7 │ Medium │
│ iphone11pro │ iPhone 11 Pro │ 16.5 │ High │
│ iphone11pro │ iPhone 11 Pro │ 16.6 │ Medium │
│ iphone12pro │ iPhone 12 Pro │ 14.8 │ Medium │
│ iphone13pro │ iPhone 13 Pro │ 15.2 │ Low │
│ iphone13pro │ iPhone 13 Pro │ 15.7 │ High │
│ iphone14pro │ iPhone 14 Pro │ 16.5 │ High │
│ iphone14pro │ iPhone 14 Pro │ 16.6 │ Low │
│ iphone8 │ iPhone 8 │ 14.7 │ Medium │
│ iphone8 │ iPhone 8 │ 15.7 │ Medium │
│ iphone8 │ iPhone 8 │ 16.5 │ High │
│ iphone8 │ iPhone 8 │ 16.6 │ Medium │
└─────────────┴───────────────────────┴───────────────┴─────────────────┘
```
summary: |
Format:
One device configuration per line and the parameters are separated with `,` in the order of: `deviceID,version,language,orientation`
For example:
`iphone8,14.7,en,portrait`
`iphone8,14.7,en,landscape`
Available devices and its versions:
```
┌─────────────┬───────────────────────┬─────────────────────┬─────────────────────────────────┐
│ MODEL_ID │ NAME │ OS_VERSION_IDS │ TAGS │
├─────────────┼───────────────────────┼─────────────────────┼─────────────────────────────────┤
│ ipad5 │ iPad (5th generation) │ 15.4 │ reduced_stability=15.4 │
│ ipadmini4 │ iPad mini 4 │ 15.4 │ │
│ iphone11pro │ iPhone 11 Pro │ 14.7,16.5,16.6 │ deprecated=16.5 │
│ iphone12pro │ iPhone 12 Pro │ 14.8 │ │
│ iphone13pro │ iPhone 13 Pro │ 15.2,15.7 │ reduced_stability=15.2, default │
│ iphone14pro │ iPhone 14 Pro │ 16.5,16.6 │ deprecated=16.5 │
│ iphone8 │ iPhone 8 │ 14.7,15.7,16.5,16.6 │ deprecated=16.5 │
└─────────────┴───────────────────────┴─────────────────────┴─────────────────────────────────┘
```
Device and OS Capacity:
```
┌─────────────┬───────────────────────┬───────────────┬─────────────────┐
│ MODEL_ID │ MODEL_NAME │ OS_VERSION_ID │ DEVICE_CAPACITY │
├─────────────┼───────────────────────┼───────────────┼─────────────────┤
│ ipad5 │ iPad (5th generation) │ 15.4 │ Low │
│ ipadmini4 │ iPad mini 4 │ 15.4 │ Low │
│ iphone11pro │ iPhone 11 Pro │ 14.7 │ Medium │
│ iphone11pro │ iPhone 11 Pro │ 16.5 │ High │
│ iphone11pro │ iPhone 11 Pro │ 16.6 │ Medium │
│ iphone12pro │ iPhone 12 Pro │ 14.8 │ Medium │
│ iphone13pro │ iPhone 13 Pro │ 15.2 │ Low │
│ iphone13pro │ iPhone 13 Pro │ 15.7 │ High │
│ iphone14pro │ iPhone 14 Pro │ 16.5 │ High │
│ iphone14pro │ iPhone 14 Pro │ 16.6 │ Low │
│ iphone8 │ iPhone 8 │ 14.7 │ Medium │
│ iphone8 │ iPhone 8 │ 15.7 │ Medium │
│ iphone8 │ iPhone 8 │ 16.5 │ High │
│ iphone8 │ iPhone 8 │ 16.6 │ Medium │
└─────────────┴───────────────────────┴───────────────┴─────────────────┘
```
is_required: true
- test_timeout: 900
opts:
category: "Debug"
title: "Test timeout"
summary: |
Max time a test execution is allowed to run before it is automatically canceled. The default value is 900 (15 min). Duration in seconds with up to nine fractional digits. Example: "3.5".
description: |
Max time a test execution is allowed to run before it is automatically canceled. The default value is 900 (15 min). Duration in seconds with up to nine fractional digits. Example: "3.5".
- download_test_results: "false"
opts:
category: "Debug"
title: "Download files"
summary: |
If this input is set to `true` all files generated in the test run will be downloaded. Otherwise, no any file will be downloaded.
description: |
If this input is set to `true` all files generated in the test run will be downloaded. Otherwise, no any file will be downloaded.
is_required: true
value_options:
- "false"
- "true"
- api_base_url: "https://vdt.bitrise.io/test"
opts:
title: "Test API's base URL"
summary: The URL where test API is accessible.
description: |
The URL where test API is accessible.
is_required: true
is_dont_change_value: true
- api_token: $ADDON_VDTESTING_API_TOKEN
opts:
title: "API Token"
summary: The token required to authenticate with the API.
description: |
The token required to authenticate with the API.
is_required: true
is_dont_change_value: true
is_sensitive: true
outputs:
- VDTESTING_DOWNLOADED_FILES_DIR:
opts:
title: "Downloaded files directory"
description: "The directory containing the downloaded files if you have set `download_test_results` inputs above."
summary: "The directory containing the downloaded files if you have set `download_test_results` inputs above."