Skip to content

Commit c07397c

Browse files
authored
[Infra] Require firestore status check only if firestore code changes (#13678)
1 parent bc2c2d4 commit c07397c

File tree

1 file changed

+13
-15
lines changed

1 file changed

+13
-15
lines changed

.github/workflows/firestore.yml

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -143,11 +143,11 @@ jobs:
143143
144144
145145
cmake-prod-db:
146+
needs: check
146147
# Either a scheduled run from public repo, or a pull request with firestore changes.
147148
if: |
148149
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
149150
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
150-
needs: check
151151
152152
strategy:
153153
matrix:
@@ -230,11 +230,11 @@ jobs:
230230
231231
232232
sanitizers-mac:
233+
needs: check
233234
# Either a scheduled run from public repo, or a pull request with firestore changes.
234235
if: |
235236
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
236237
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
237-
needs: check
238238
239239
strategy:
240240
matrix:
@@ -272,11 +272,11 @@ jobs:
272272
273273
274274
sanitizers-ubuntu:
275+
needs: check
275276
# Either a scheduled run from public repo, or a pull request with firestore changes.
276277
if: |
277278
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
278279
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
279-
needs: check
280280
281281
strategy:
282282
matrix:
@@ -318,12 +318,12 @@ jobs:
318318
319319
320320
xcodebuild:
321+
needs: check
321322
# Either a scheduled run from public repo, or a pull request with firestore changes.
322323
if: |
323324
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
324-
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
325+
(github.event_name == 'pull_request')
325326
runs-on: macos-14
326-
needs: check
327327

328328
strategy:
329329
matrix:
@@ -347,12 +347,12 @@ jobs:
347347
348348
349349
pod-lib-lint:
350+
needs: check
350351
# Either a scheduled run from public repo, or a pull request with firestore changes.
351352
if: |
352353
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
353-
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
354+
(github.event_name == 'pull_request')
354355
runs-on: macos-13
355-
needs: check
356356
strategy:
357357
matrix:
358358
podspec: [
@@ -379,8 +379,8 @@ jobs:
379379
380380
# `pod lib lint` takes a long time so only run the other platforms and static frameworks build in the cron.
381381
pod-lib-lint-cron:
382-
if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
383382
needs: check
383+
if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
384384
strategy:
385385
matrix:
386386
podspec: [
@@ -430,10 +430,11 @@ jobs:
430430
--no-analyze
431431
432432
spm-source:
433+
needs: check
433434
# Either a scheduled run from public repo, or a pull request with firestore changes.
434435
if: |
435436
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
436-
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
437+
(github.event_name == 'pull_request')
437438
strategy:
438439
matrix:
439440
target: [iOS, tvOS, macOS]
@@ -447,7 +448,6 @@ jobs:
447448
xcode: Xcode_15.3
448449
target: visionOS
449450
runs-on: ${{ matrix.os }}
450-
needs: check
451451
env:
452452
FIREBASE_SOURCE_FIRESTORE: 1
453453
steps:
@@ -463,12 +463,12 @@ jobs:
463463
run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseFirestore ${{ matrix.target }} spmbuildonly
464464

465465
spm-binary:
466+
needs: check
466467
# Either a scheduled run from public repo, or a pull request with firestore changes.
467468
if: |
468469
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
469470
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
470471
runs-on: macos-14
471-
needs: check
472472
steps:
473473
- uses: actions/checkout@v4
474474
- uses: mikehardy/buildcache-action@c87cea0ccd718971d6cc39e672c4f26815b6c126
@@ -480,12 +480,12 @@ jobs:
480480
run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseFirestore iOS spmbuildonly
481481

482482
check-firestore-internal-public-headers:
483+
needs: check
483484
# Either a scheduled run from public repo, or a pull request with firestore changes.
484485
if: |
485486
(github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') ||
486487
(github.event_name == 'pull_request' && needs.changes.outputs.changed == 'true')
487488
runs-on: macos-14
488-
needs: check
489489
steps:
490490
- uses: actions/checkout@v4
491491
- name: Assert that Firestore and FirestoreInternal have identically named headers.
@@ -551,15 +551,13 @@ jobs:
551551
# to be used as a required check for merging.
552552
check-required-tests:
553553
runs-on: ubuntu-latest
554-
if: always()
555554
name: Check all required Firestore tests results
556555
needs: [cmake, cmake-prod-db, xcodebuild, spm-source, spm-binary]
557556
steps:
558557
- name: Check test matrix
559-
if: needs.cmake.result == 'failure' || needs.cmake-prod-db.result == 'failure' || needs.xcodebuild.result == 'failure' || needs.spm.result == 'failure'
558+
if: needs.*.result == 'failure'
560559
run: exit 1
561560

562-
563561
# Disable until FirebaseUI is updated to accept Firebase 9 and quickstart is updated to accept
564562
# Firebase UI 12
565563
# quickstart:

0 commit comments

Comments
 (0)