Skip to content

Commit 508f29d

Browse files
authored
Add distributed SPM CI builds and tests (#6271)
1 parent 802cb6a commit 508f29d

30 files changed

+1954
-4
lines changed

.github/workflows/abtesting.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,38 @@ jobs:
2929
scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseABTesting.podspec \
3030
--platforms=${{ matrix.target }}
3131
32+
spm:
33+
# Don't run on private repo unless it is a PR.
34+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
35+
runs-on: macOS-latest
36+
steps:
37+
- uses: actions/checkout@v2
38+
- name: Xcode 12
39+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
40+
- name: Initialize xcodebuild
41+
run: xcodebuild -list
42+
- name: iOS Unit Tests
43+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme ABTestingUnit test -sdk
44+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
45+
46+
spm-cron:
47+
# Don't run on private repo.
48+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
49+
50+
runs-on: macOS-latest
51+
steps:
52+
- uses: actions/checkout@v2
53+
- name: Xcode 12
54+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
55+
- name: Initialize xcodebuild
56+
run: xcodebuild -list
57+
- name: macOS Unit Tests
58+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme ABTestingUnit test | xcpretty
59+
- name: tvOS Unit Tests
60+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme ABTestingUnit test -sdk
61+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
62+
63+
3264
catalyst:
3365
# Don't run on private repo unless it is a PR.
3466
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/auth.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,37 @@ jobs:
6363
- name: BuildAndTest # can be replaced with pod lib lint with CocoaPods 1.10
6464
run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/build.sh Auth iOS)
6565

66+
spm:
67+
# Don't run on private repo unless it is a PR.
68+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
69+
runs-on: macOS-latest
70+
steps:
71+
- uses: actions/checkout@v2
72+
- name: Xcode 12
73+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
74+
- name: Initialize xcodebuild
75+
run: xcodebuild -list
76+
- name: iOS Unit Tests
77+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme AuthUnit test -sdk
78+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
79+
80+
spm-cron:
81+
# Don't run on private repo.
82+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
83+
84+
runs-on: macOS-latest
85+
steps:
86+
- uses: actions/checkout@v2
87+
- name: Xcode 12
88+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
89+
- name: Initialize xcodebuild
90+
run: xcodebuild -list
91+
- name: macOS Unit Tests
92+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme AuthUnit test | xcpretty
93+
- name: tvOS Unit Tests
94+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme AuthUnit test -sdk
95+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
96+
6697
catalyst:
6798
# Don't run on private repo unless it is a PR.
6899
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/core.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,37 @@ jobs:
2828
- name: Build and test
2929
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseCore.podspec --platforms=${{ matrix.target }}
3030

31+
spm:
32+
# Don't run on private repo unless it is a PR.
33+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
34+
runs-on: macOS-latest
35+
steps:
36+
- uses: actions/checkout@v2
37+
- name: Xcode 12
38+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
39+
- name: Initialize xcodebuild
40+
run: xcodebuild -list
41+
- name: iOS Unit Tests
42+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme CoreUnit test -sdk
43+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
44+
45+
spm-cron:
46+
# Don't run on private repo.
47+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
48+
49+
runs-on: macOS-latest
50+
steps:
51+
- uses: actions/checkout@v2
52+
- name: Xcode 12
53+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
54+
- name: Initialize xcodebuild
55+
run: xcodebuild -list
56+
- name: macOS Unit Tests
57+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme CoreUnit test | xcpretty
58+
- name: tvOS Unit Tests
59+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme CoreUnit test -sdk
60+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
61+
3162
catalyst:
3263
# Don't run on private repo unless it is a PR.
3364
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/crashlytics.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,38 @@ jobs:
3030
run: |
3131
scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseCrashlytics.podspec --platforms=${{ matrix.target }}
3232
33+
spm:
34+
# Don't run on private repo unless it is a PR.
35+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
36+
runs-on: macOS-latest
37+
steps:
38+
- uses: actions/checkout@v2
39+
- name: Xcode 12
40+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
41+
- name: Initialize xcodebuild
42+
run: xcodebuild -list
43+
- name: iOS Unit Tests
44+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseCrashlytics build -sdk
45+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
46+
47+
spm-cron:
48+
# Don't run on private repo.
49+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
50+
51+
runs-on: macOS-latest
52+
steps:
53+
- uses: actions/checkout@v2
54+
- name: Xcode 12
55+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
56+
- name: Initialize xcodebuild
57+
run: xcodebuild -list
58+
- name: macOS Unit Tests
59+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseCrashlytics build | xcpretty
60+
- name: tvOS Unit Tests
61+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseCrashlytics build -sdk
62+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
63+
64+
3365
catalyst:
3466
# Don't run on private repo unless it is a PR.
3567
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/database.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,37 @@ jobs:
4040
# Only iOS to mitigate flakes.
4141
run: scripts/third_party/travis/retry.sh scripts/build.sh Database iOS integration
4242

43+
spm:
44+
# Don't run on private repo unless it is a PR.
45+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
46+
runs-on: macOS-latest
47+
steps:
48+
- uses: actions/checkout@v2
49+
- name: Xcode 12
50+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
51+
- name: Initialize xcodebuild
52+
run: xcodebuild -list
53+
- name: iOS Unit Tests
54+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme DatabaseUnit test -sdk
55+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
56+
57+
spm-cron:
58+
# Don't run on private repo.
59+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
60+
61+
runs-on: macOS-latest
62+
steps:
63+
- uses: actions/checkout@v2
64+
- name: Xcode 12
65+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
66+
- name: Initialize xcodebuild
67+
run: xcodebuild -list
68+
- name: macOS Unit Tests
69+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme DatabaseUnit test | xcpretty
70+
- name: tvOS Unit Tests
71+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme DatabaseUnit test -sdk
72+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
73+
4374
catalyst:
4475
# Don't run on private repo unless it is a PR.
4576
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/dynamiclinks.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,20 @@ jobs:
2424
- name: FirebaseDynamicLinks
2525
run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseDynamicLinks.podspec
2626

27+
spm:
28+
# Don't run on private repo unless it is a PR.
29+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
30+
runs-on: macOS-latest
31+
steps:
32+
- uses: actions/checkout@v2
33+
- name: Xcode 12
34+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
35+
- name: Initialize xcodebuild
36+
run: xcodebuild -list
37+
- name: iOS Unit Tests
38+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseDynamicLinks build -sdk
39+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
40+
2741
dynamiclinks-cron-only:
2842
# Don't run on private repo.
2943
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'

.github/workflows/firestore.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,37 @@ jobs:
185185
--platforms=ios \
186186
--allow-warnings
187187
188+
spm:
189+
# Don't run on private repo unless it is a PR.
190+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
191+
runs-on: macOS-latest
192+
steps:
193+
- uses: actions/checkout@v2
194+
- name: Xcode 12
195+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
196+
- name: Initialize xcodebuild
197+
run: xcodebuild -list
198+
- name: iOS Unit Tests
199+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFirestore build -sdk
200+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
201+
202+
spm-cron:
203+
# Don't run on private repo.
204+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
205+
206+
runs-on: macOS-latest
207+
steps:
208+
- uses: actions/checkout@v2
209+
- name: Xcode 12
210+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
211+
- name: Initialize xcodebuild
212+
run: xcodebuild -list
213+
- name: macOS Unit Tests
214+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFirestore build | xcpretty
215+
- name: tvOS Unit Tests
216+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFirestore build -sdk
217+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
218+
188219
quickstart:
189220
# Don't run on private repo unless it is a PR.
190221
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/functions.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,37 @@ on:
1313

1414
jobs:
1515

16+
spm:
17+
# Don't run on private repo unless it is a PR.
18+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
19+
runs-on: macOS-latest
20+
steps:
21+
- uses: actions/checkout@v2
22+
- name: Xcode 12
23+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
24+
- name: Initialize xcodebuild
25+
run: xcodebuild -list
26+
- name: iOS Unit Tests
27+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFunctions build -sdk
28+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
29+
30+
spm-cron:
31+
# Don't run on private repo.
32+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
33+
34+
runs-on: macOS-latest
35+
steps:
36+
- uses: actions/checkout@v2
37+
- name: Xcode 12
38+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
39+
- name: Initialize xcodebuild
40+
run: xcodebuild -list
41+
- name: macOS Unit Tests
42+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFunctions build | xcpretty
43+
- name: tvOS Unit Tests
44+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseFunctions build -sdk
45+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
46+
1647
quickstart:
1748
# Don't run on private repo unless it is a PR.
1849
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/inappmessaging.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,20 @@ on:
1313

1414
jobs:
1515

16+
spm:
17+
# Don't run on private repo unless it is a PR.
18+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
19+
runs-on: macOS-latest
20+
steps:
21+
- uses: actions/checkout@v2
22+
- name: Xcode 12
23+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
24+
- name: Initialize xcodebuild
25+
run: xcodebuild -list
26+
- name: iOS Unit Tests
27+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseInAppMessaging build -sdk
28+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
29+
1630
quickstart:
1731
# Don't run on private repo unless it is a PR.
1832
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'

.github/workflows/installations.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,37 @@ jobs:
4040
scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseInstallations.podspec \
4141
--platforms=${{ matrix.target }} --ignore-local-podspecs=FirebaseInstanceID.podspec
4242
43+
spm:
44+
# Don't run on private repo unless it is a PR.
45+
if: github.repository != 'FirebasePrivate/firebase-ios-sdk' || github.event_name == 'pull_request'
46+
runs-on: macOS-latest
47+
steps:
48+
- uses: actions/checkout@v2
49+
- name: Xcode 12
50+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
51+
- name: Initialize xcodebuild
52+
run: xcodebuild -list
53+
- name: iOS Unit Tests
54+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseInstanceID build -sdk
55+
iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11' | xcpretty
56+
57+
spm-cron:
58+
# Don't run on private repo.
59+
if: github.event_name == 'schedule' && github.repository != 'FirebasePrivate/firebase-ios-sdk'
60+
61+
runs-on: macOS-latest
62+
steps:
63+
- uses: actions/checkout@v2
64+
- name: Xcode 12
65+
run: sudo xcode-select -s /Applications/Xcode_12_beta.app/Contents/Developer
66+
- name: Initialize xcodebuild
67+
run: xcodebuild -list
68+
- name: macOS Unit Tests
69+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseInstanceID build | xcpretty
70+
- name: tvOS Unit Tests
71+
run: scripts/third_party/travis/retry.sh xcodebuild -scheme FirebaseInstanceID build -sdk
72+
appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV' | xcpretty
73+
4374
# TODO - Catalyst is disabled because `pod gen` does not have a way to get some dependent pods
4475
# from a local path and the Installations podspec requires that FirebaseInstanceID.podspec not be
4576
# the local version.

0 commit comments

Comments
 (0)