segmentation.yml 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. name: segmentation
  2. on:
  3. pull_request:
  4. paths:
  5. - 'FirebaseSegmentation**'
  6. - '.github/workflows/segmentation.yml'
  7. - 'Gemfile*'
  8. schedule:
  9. # Run every day at 12am (PST) - cron uses UTC times
  10. - cron: '0 8 * * *'
  11. jobs:
  12. pod-lib-lint:
  13. # Don't run on private repo unless it is a PR.
  14. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  15. runs-on: macos-11
  16. strategy:
  17. matrix:
  18. target: [ios, tvos, macos]
  19. steps:
  20. - uses: actions/checkout@v2
  21. - name: Setup Bundler
  22. run: scripts/setup_bundler.sh
  23. - name: Build and test
  24. run: |
  25. scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseSegmentation.podspec --platforms=${{ matrix.target }}
  26. catalyst:
  27. # Don't run on private repo unless it is a PR.
  28. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  29. runs-on: macos-11
  30. steps:
  31. - uses: actions/checkout@v2
  32. - uses: mikehardy/buildcache-action@50738c6c77de7f34e66b870e4f8ede333b69d077
  33. with:
  34. cache_key: ${{ matrix.os }}
  35. - name: Setup Bundler
  36. run: scripts/setup_bundler.sh
  37. - name: Setup project and Build for Catalyst
  38. run: scripts/test_catalyst.sh FirebaseSegmentation test FirebaseSegmentation-Unit-unit
  39. segmentation-cron-only:
  40. # Don't run on private repo.
  41. if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
  42. runs-on: macos-11
  43. strategy:
  44. matrix:
  45. target: [ios, tvos, macos]
  46. flags: [
  47. '--use-static-frameworks',
  48. '--use-libraries'
  49. ]
  50. needs: pod-lib-lint
  51. steps:
  52. - uses: actions/checkout@v2
  53. - name: Setup Bundler
  54. run: scripts/setup_bundler.sh
  55. - name: PodLibLint Auth Cron
  56. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseSegmentation.podspec --platforms=${{ matrix.target }} ${{ matrix.flags }}
  57. segmentation-sample-build-test:
  58. # Don't run on private repo unless it is a PR.
  59. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  60. runs-on: macos-11
  61. steps:
  62. - uses: actions/checkout@v2
  63. - uses: mikehardy/buildcache-action@50738c6c77de7f34e66b870e4f8ede333b69d077
  64. with:
  65. cache_key: ${{ matrix.os }}
  66. - name: Setup Bundler
  67. run: scripts/setup_bundler.sh
  68. - name: Install Secret GoogleService-Info.plist
  69. # Just copy a dummy plist for a build-only test
  70. run: cp FirebaseCore/Tests/Unit/Resources/GoogleService-Info.plist FirebaseSegmentation/Tests/Sample/
  71. - name: Prereqs
  72. run: scripts/install_prereqs.sh SegmentationSample iOS
  73. - name: Build
  74. run: scripts/build.sh SegmentationSample iOS