chore(deps-dev): bump @storybook/react from 8.6.14 to 9.1.12 #87
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Downstream Trigger | ||
| on: | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| jobs: | ||
| check-pr-source: | ||
| name: Check PR Source Branch | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| is_from_dev: ${{ steps.check_branch.outputs.is_from_dev }} | ||
| steps: | ||
| - name: Check if workflow is operating from dev branch | ||
| id: check_branch | ||
| run: | | ||
| IS_FROM_DEV="false" | ||
| # For pull requests, check if the source branch is dev | ||
| if [[ "${{ github.event_name }}" == "pull_request" && "${{ github.head_ref }}" == "dev" ]]; then | ||
| IS_FROM_DEV="true" | ||
| echo "This is a pull request coming from the dev branch into main." | ||
| else | ||
| echo "This PR is not from dev to main (PR head: ${{ github.head_ref }}, PR base: ${{ github.base_ref }}). Downstream staging will be skipped." | ||
| fi | ||
| echo "is_from_dev=$IS_FROM_DEV" >> $GITHUB_OUTPUT | ||
| echo "Branch check result: is_from_dev = $IS_FROM_DEV" | ||
| run-tests: | ||
| name: Run Pytest Comparison | ||
| # No explicit check_pr_source dependency, tests should run for any PR to main. | ||
| # If tests pass and PR is from dev, then downstream will run. | ||
| uses: JamesonRGrieve/Workflows/.github/workflows/test-pytest.yml@main | ||
|
Check failure on line 33 in .github/workflows/test-downstream.yml
|
||
| with: | ||
| # PR is to main, so compare PR branch against main. | ||
| target_branch_to_compare: ${{ github.base_ref }} # This will be 'main' | ||
| permissions: | ||
| contents: write # For lint within pytest | ||
| call-reusable-stage-downstream: | ||
| name: Call Reusable Stage Downstream Workflow | ||
| needs: [check-pr-source, run-tests] # Ensures tests pass and branch is correct before staging | ||
| if: needs.check-pr-source.outputs.is_from_dev == 'true' | ||
| uses: JamesonRGrieve/Workflows/.github/workflows/test-downstream.yml@main | ||
| with: | ||
| source_repo_ref: 'dev' # Staging happens from the 'dev' branch of the current repo | ||
| secrets: | ||
| PAT_TOKEN: ${{ secrets.PAT_TOKEN }} | ||
| DOWNSTREAM_REPOSITORIES: ${{ secrets.DOWNSTREAM_REPOSITORIES }} | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| # Permissions are handled by the reusable workflow itself. | ||