reusable-quickstart.yml 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. name: Reusable Quickstart Test
  2. on:
  3. workflow_call:
  4. inputs:
  5. quickstart-name:
  6. required: true
  7. type: string
  8. legacy:
  9. required: false
  10. type: boolean
  11. default: false
  12. runs-on:
  13. required: true
  14. type: string
  15. test-command:
  16. required: true
  17. type: string
  18. extra-setup-command:
  19. required: false
  20. type: string
  21. post-test-command:
  22. required: false
  23. type: string
  24. xcode-version:
  25. required: false
  26. type: string
  27. secrets:
  28. GHASecretsGPGPassphrase1:
  29. required: true
  30. RELEASE_TESTING_PAT:
  31. required: true
  32. jobs:
  33. quickstart:
  34. runs-on: ${{ inputs.runs-on }}
  35. env:
  36. plist_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  37. signin_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  38. botaccess: ${{ secrets.RELEASE_TESTING_PAT }}
  39. LEGACY: ${{ inputs.legacy }}
  40. steps:
  41. - uses: actions/checkout@v4
  42. - uses: ruby/setup-ruby@v1
  43. - name: Select Xcode version
  44. if: ${{ inputs.xcode-version }}
  45. run: sudo xcode-select -s /Applications/Xcode_${{ inputs.xcode-version }}.app/Contents/Developer
  46. - name: Setup testing repo and quickstart
  47. run: BOT_TOKEN="${{ secrets.RELEASE_TESTING_PAT }}" scripts/setup_quickstart.sh ${{ inputs.quickstart-name }} nightly_release_testing
  48. - name: Extra setup
  49. if: ${{ inputs.extra-setup-command }}
  50. run: ${{ inputs.extra-setup-command }}
  51. - name: Install Secret GoogleService-Info.plist
  52. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/qs-${{ inputs.quickstart-name }}.plist.gpg quickstart-ios/${{ inputs.quickstart-name }}/GoogleService-Info.plist "$plist_secret"
  53. - name: Test quickstart
  54. run: ${{ inputs.test-command }}
  55. - name: Post-test
  56. if: ${{ inputs.post-test-command }}
  57. run: ${{ inputs.post-test-command }}
  58. - name: Remove data before upload
  59. if: ${{ failure() }}
  60. run: scripts/remove_data.sh ${{ inputs.quickstart-name }}
  61. - uses: actions/upload-artifact@v4
  62. if: ${{ failure() }}
  63. with:
  64. name: quickstart_artifacts_${{ inputs.quickstart-name }}
  65. path: quickstart-ios/