forked from stripe/stripe-ios
-
Notifications
You must be signed in to change notification settings - Fork 0
/
bitrise.yml
610 lines (609 loc) · 17.5 KB
/
bitrise.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
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
format_version: "11"
default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
project_type: ios
app:
envs:
- FASTLANE_XCODE_LIST_TIMEOUT: "120"
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.4
- BITRISE_PROJECT_PATH: Stripe.xcworkspace
- GIT_AUTHOR_NAME: Bitrise CI
- GIT_AUTHOR_EMAIL: [email protected]
- GIT_COMMITTER_NAME: Bitrise CI
- GIT_COMMITTER_EMAIL: [email protected]
- opts:
is_expand: false
FASTLANE_WORK_DIR: .
- opts:
is_expand: false
FASTLANE_LANE: ios integration_all
trigger_map:
- push_branch: master
pipeline: main-trigger-pipeline
- pull_request_source_branch: releases/*
pipeline: releases-trigger-pipeline
- pull_request_source_branch: '*'
pipeline: main-trigger-pipeline
pipelines:
main-trigger-pipeline:
stages:
- stage-trigger-run-all: {}
releases-trigger-pipeline:
stages:
- stage-releases-run-all: {}
nightly-pipeline:
stages:
- stage-nightly-all: {}
stages:
stage-trigger-run-all:
workflows:
- framework-tests: {}
- test-builds-xcode-143: {}
- test-builds-xcode-15: {}
- test-builds-xcode-143-release: {}
- test-builds-vision: {}
- install-tests-non-carthage: {}
- lint-tests: {}
- size-report: {}
- ui-tests-1: {}
- ui-tests-2: {}
- integration-all: {}
- deploy-dry-run: {}
stage-releases-run-all:
workflows:
- framework-tests: {}
- test-builds-xcode-143: {}
- test-builds-xcode-15: {}
- test-builds-vision: {}
- deploy-docs: {}
- install-tests-non-carthage: {}
- lint-tests: {}
- size-report: {}
- basic-integration-tests: {}
- ui-tests-1: {}
- ui-tests-2: {}
- legacy-tests-14: {}
- carthage-install-test: {}
- pod-lint-tests: {}
- integration-all: {}
stage-nightly-all:
workflows:
- basic-integration-tests: {}
- check-docs: {}
- legacy-tests-14: {}
- carthage-install-test: {}
- data-theorem-sast: {}
- deploy-dry-run: {}
- pod-lint-tests: {}
workflows:
basic-integration-tests:
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: Basic Integration
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
after_run:
- notify_ci
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
carthage-install-test:
steps:
- fastlane@3:
inputs:
- lane: installation_carthage
title: fastlane installation_carthage
before_run:
- prep_all
after_run:
- notify_ci
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
check-docs:
steps:
- script@1:
inputs:
- content: bundle exec ./ci_scripts/build_documentation.rb
title: Build documentation
before_run:
- prep_all
after_run:
- notify_ci
data-theorem-sast:
steps:
- script@1:
inputs:
- content: bundle config set path 'vendor/bundle'
is_always_run: true
title: Set Bundler to use local vendor directory
- script@1:
inputs:
- content: bundle config set without 'development'
title: Set bundler to ignore development and test gems
- git-clone@6: {}
- cache-pull@2: {}
- bundler@0: {}
- cache-push@2:
inputs:
- compress_archive: "true"
- cache_paths: |
vendor
SourcePackages
- script@1:
inputs:
- content: bundle exec ./ci_scripts/push_dt.rb "$BITRISE_GIT_BRANCH" "$DT_UPLOAD_API_KEY"
title: Submit app to Data Theorem for SAST
after_run:
- notify_ci
deploy-docs:
steps:
- activate-ssh-key@4: {}
- script@1:
inputs:
- content: bundle config set path 'vendor/bundle'
is_always_run: true
title: Set Bundler to use local vendor directory
- git-clone@6:
inputs:
- merge_pr: "no"
- fetch_tags: "yes"
- cache-pull@2: {}
- bundler@0: {}
- cache-push@2:
inputs:
- compress_archive: "true"
- cache_paths: |
vendor
SourcePackages
- script@1:
inputs:
- content: git fetch origin
title: Fetch full branch history
- script@1:
inputs:
- content: bundle exec ./ci_scripts/build_documentation.rb --publish
title: Build documentation
deploy-dry-run:
steps:
- script@1:
inputs:
- content: brew install sourcekitten
is_always_run: true
title: Install Sourcekitten
- script@1:
inputs:
- content: bundle exec ./ci_scripts/create_release.rb --version 99.99.99 --dry-run
is_always_run: true
title: Create release
- script@1:
inputs:
- content: bundle exec ./ci_scripts/deploy_release.rb --dry-run
is_always_run: true
title: Deploy release
before_run:
- prep_all
after_run:
- notify_ci
meta:
bitrise.io:
stack: osx-xcode-14.1.x-ventura
machine_type_id: g2-m1.8core
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
deploy-example-apps:
steps:
- set-xcode-build-number@1:
inputs:
- plist_path: '$BITRISE_SOURCE_DIR/Example/PaymentSheet Example/PaymentSheet Example/Info.plist'
- set-xcode-build-number@1:
inputs:
- plist_path: '$BITRISE_SOURCE_DIR/Example/IdentityVerification Example/IdentityVerification Example/Info.plist'
- xcode-archive@4:
inputs:
- project_path: Stripe.xcworkspace
- distribution_method: app-store
- automatic_code_signing: apple-id
- xcodebuild_options: DEVELOPMENT_TEAM=Y28TH9SHX7
- scheme: PaymentSheet Example
- xcode-archive@4:
inputs:
- project_path: Stripe.xcworkspace
- distribution_method: app-store
- automatic_code_signing: apple-id
- xcodebuild_options: DEVELOPMENT_TEAM=Y28TH9SHX7
- scheme: IdentityVerification Example
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
financial-connections-stability-tests:
before_run:
- prep_all
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: FinancialConnections Example
- pagerduty@0:
is_always_run: true
run_if: .IsBuildFailed
inputs:
- event_description: iOS E2E tests failing! $BITRISE_BUILD_URL.
- integration_key: $AUX_PAGERDUTY_INTEGRATION_KEY
- slack@3:
is_always_run: true
run_if: .IsBuildFailed
inputs:
- webhook_url: $SLACK_KGAIDIS_TESTING_WEBHOOK_URL
- webhook_url_on_error: $SLACK_KGAIDIS_TESTING_WEBHOOK_URL
- deploy-to-bitrise-io@2: {}
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
financial-connections-stability-tests-for-edge:
before_run:
- prep_all
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: FinancialConnections Example
- deploy-to-bitrise-io@2: {}
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
framework-tests:
steps:
- fastlane@3:
inputs:
- lane: preflight
title: fastlane preflight
- fastlane@3:
inputs:
- lane: threeds2_tests
title: fastlane threeds2_tests
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeiOS
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripePayments
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripePaymentsUI
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripePaymentSheet
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeCameraCore
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeCore
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeIdentity
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeFinancialConnections
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeCardScan
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeApplePay
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: StripeUICore
- deploy-to-bitrise-io@2: {}
- save-spm-cache@1: {}
before_run:
- prep_all
after_run: []
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1.8core
test-builds-xcode-143:
steps:
- xcode-build-for-test@2:
inputs:
- scheme: AllStripeFrameworks
- destination: $DEFAULT_TEST_DEVICE
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1.8core
test-builds-xcode-143-release:
steps:
- script@1:
inputs:
- content: xcodebuild build -workspace "Stripe.xcworkspace" -scheme "AllStripeFrameworks" -configuration "Release" -sdk "iphonesimulator" | xcpretty
title: Build release builds
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1.8core
test-builds-xcode-15:
steps:
- xcode-build-for-test@2:
inputs:
- scheme: AllStripeFrameworks
- destination: generic/platform=iOS Simulator
- deploy-to-bitrise-io@2: {}
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 15,OS=17.0
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-15.0.x
machine_type_id: g2-m1.8core
test-builds-vision:
steps:
- xcode-build-for-test@2:
inputs:
- scheme: StripePaymentSheet
- destination: generic/platform=visionOS Simulator
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-15.1.x-edge
machine_type_id: g2-m1.8core
install-tests-non-carthage:
steps:
- fastlane@3:
inputs:
- lane: installation_cocoapods_without_frameworks_objc
title: fastlane installation_cocoapods_without_frameworks_objc
- fastlane@3:
inputs:
- lane: installation_cocoapods_frameworks_objc
title: fastlane installation_cocoapods_frameworks_objc
- fastlane@3:
inputs:
- lane: installation_cocoapods_frameworks_swift
title: fastlane installation_cocoapods_frameworks_swift
- fastlane@3:
inputs:
- lane: installation_spm_objc
title: fastlane installation_spm_objc
- fastlane@3:
inputs:
- lane: installation_spm_swift
title: fastlane installation_spm_swift
before_run:
- prep_all
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
integration-all:
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: IntegrationTester
- log_formatter: xcbeautify
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.1.x-ventura
machine_type_id: g2-m1-max.10core
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
legacy-tests-14:
steps:
- fastlane@3:
inputs:
- lane: legacy_tests_14
title: fastlane legacy_tests_14
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 8,OS=14.5
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1.8core
before_run:
- prep_all
after_run:
- upload_logs
- notify_ci
lint-tests:
steps:
- script@1:
inputs:
- content: ./ci_scripts/lint_modified_files.sh
title: Run swiftlint
- script@1:
inputs:
- content: ./ci_scripts/check_paymentsheet_test_sharding.rb
title: Check PaymentSheet test sharding
- script@1:
inputs:
- content: ./ci_scripts/check_image_format.sh
title: Check png image format is 8-bit
- fastlane@3:
inputs:
- lane: build_extras
title: fastlane build_extras
- fastlane@3:
inputs:
- lane: analyze
title: fastlane analyze
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1.8core
notify_ci:
steps:
- script@1:
inputs:
- content: ./ci_scripts/notify_ci.rb
title: Send notification if failed
is_always_run: true
run_if: .IsBuildFailed
pod-lint-tests:
steps:
- script@1:
inputs:
- content: pod lib lint --include-podspecs='*.podspec'
title: pod lib lint
before_run:
- prep_all
envs:
- DEFAULT_TEST_DEVICE: platform=iOS Simulator,name=iPhone 12 mini,OS=16.1
prep_all:
steps:
- xcode-start-simulator@0:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- set-env-var@0:
inputs:
- destination_keys: CONFIGURATION_BUILD_DIR
- value: $BITRISE_SOURCE_DIR/stpbuild/products
title: Set CONFIGURATION_BUILD_DIR
- set-env-var@0:
inputs:
- destination_keys: CONFIGURATION_TEMP_DIR
- value: $BITRISE_SOURCE_DIR/stpbuild/intermediates
title: Set CONFIGURATION_TEMP_DIR
- script@1:
inputs:
- content: bundle config set path 'vendor/bundle'
is_always_run: true
title: Set Bundler to use local vendor directory
- git-clone@6:
inputs:
- clone_depth: "1"
- cache-pull@2: {}
- bundler@0: {}
- cache-push@2:
inputs:
- compress_archive: "true"
- cache_paths: |
vendor
- restore-spm-cache@1: {}
size-report:
steps:
- script@1:
inputs:
- content: bundle config set path 'vendor/bundle'
is_always_run: true
title: Set Bundler to use local vendor directory
- git-clone@6:
inputs:
- merge_pr: "no"
- fetch_tags: "yes"
- cache-pull@2: {}
- bundler@0: {}
- cache-push@2:
inputs:
- compress_archive: "true"
- cache_paths: |
vendor
SourcePackages
- script@1:
inputs:
- content: git fetch origin
title: Fetch full branch history
- script@1:
inputs:
- content: bundle exec fastlane size_report
title: Generate size report
ui-tests-1:
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: PaymentSheet Example
- test_plan: PaymentSheet Example-Shard1
- log_formatter: xcbeautify
- xcodebuild_options: -maximum-concurrent-test-simulator-destinations 2 -maximum-parallel-testing-workers 2
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1-max.10core
ui-tests-2:
steps:
- xcode-test@4:
inputs:
- destination: $DEFAULT_TEST_DEVICE
- test_repetition_mode: retry_on_failure
- maximum_test_repetitions: "5"
- scheme: PaymentSheet Example
- test_plan: PaymentSheet Example-Shard2
- log_formatter: xcbeautify
- xcodebuild_options: -maximum-concurrent-test-simulator-destinations 2 -maximum-parallel-testing-workers 2
- deploy-to-bitrise-io@2: {}
before_run:
- prep_all
meta:
bitrise.io:
stack: osx-xcode-14.3.x-ventura
machine_type_id: g2-m1-max.10core
upload_logs:
steps:
- deploy-to-bitrise-io@2:
inputs:
- notify_user_groups: none
- is_compress: "true"
- deploy_path: build-ci-tests/Logs/Test
- is_enable_public_page: "false"
title: Deploy test log artifacts
meta:
bitrise.io:
stack: osx-xcode-14.1.x-ventura
machine_type_id: g2-m1.8core