name: _quickstart.framework permissions: contents: read on: workflow_call: inputs: # The product to be tested (e.g. `ABTesting`). product: required: true type: string # Optional. The scheme to be tested (e.g. `ABTesting (tvOS)`). scheme: required: false type: string default: '' # The Run ID of a successful zip packaging workflow. zip_run_id: required: true type: string # The name of the artifact from the zip packaging workflow to download. artifact_name: required: true type: string # A command to execute before testing. # # Example: `scripts/setup_quickstart.sh functions` setup_command: required: true type: string # The path to the encrypted `GoogleService-Info.plist` file. plist_src_path: required: true type: string # The destination path for the decrypted `GoogleService-Info.plist` file. plist_dst_path: required: true type: string # The runner to use. os: required: false type: string default: macos-26 # The version of Xcode to use. xcode: required: false type: string default: Xcode_26.4 secrets: # The passphrase for decrypting the GoogleService-Info.plist. plist_secret: required: true jobs: quickstart_framework: if: github.event.pull_request.head.repo.fork == false && !cancelled() env: plist_secret: ${{ secrets.plist_secret }} SDK: ${{ inputs.product }} SCHEME: ${{ inputs.scheme }} runs-on: ${{ inputs.os }} steps: - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 with: persist-credentials: false - name: Get framework dir uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0 with: name: ${{ inputs.artifact_name }} run-id: ${{ inputs.zip_run_id }} github-token: ${{ secrets.github_token }} - uses: ruby/setup-ruby@89f90524b88a01fe6e0b732220432cc6142926af # v1.313.0 - name: Xcode env: XCODE_VERSION: ${{ inputs.xcode }} run: sudo xcode-select -s /Applications/"$XCODE_VERSION".app/Contents/Developer - name: Setup simulator uses: ./.github/actions/setup_simulator with: platform: iOS - name: Setup Bundler run: ./scripts/setup_bundler.sh - name: Move frameworks run: | mkdir -p "${HOME}"/ios_frameworks/ find "${GITHUB_WORKSPACE}" -name "Firebase*latest.zip" -exec unzip -d "${HOME}"/ios_frameworks/ {} + - name: Setup quickstart run: ${{ inputs.setup_command }} # zizmor: ignore[template-injection] - name: Install Secret GoogleService-Info.plist env: PLIST_SRC_PATH: ${{ inputs.plist_src_path }} PLIST_DST_PATH: ${{ inputs.plist_dst_path }} run: scripts/decrypt_gha_secret.sh "$PLIST_SRC_PATH" \ "$PLIST_DST_PATH" "$plist_secret" - name: Test Quickstart uses: nick-fields/retry@ad984534de44a9489a53aefd81eb77f87c70dc60 # v4.0.0 with: timeout_minutes: 15 max_attempts: 2 retry_wait_seconds: 120 command: ([ -z $plist_secret ] || scripts/test_quickstart_framework.sh "${SDK}" "${SCHEME}") # Failure sequence to upload artifact. - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 if: failure() with: name: quickstart_artifacts_${{ inputs.product }}_${{ inputs.artifact_name }} path: | quickstart-ios/ !quickstart-ios/**/GoogleService-Info.plist