Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/scripts/tests/agent-ingress-workflow.bats
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,10 @@ ROLES=(dev-lead pr-auto-review pr-review pr-review-mention ci-failure-analyst)
[[ "$output" == *"/pr-auto-review-reusable.yml@pr-auto-review/v1-stable" ]]
run yq '.jobs.pr-review.uses' "$WORKFLOW"
[ "$status" -eq 0 ]
[[ "$output" == *"/pr-review.yml@pr-review/stable" ]]
[[ "$output" == *"/pr-review.yml@pr-review/v1-stable" ]]
run yq '.jobs.pr-review.with.agent_ref' "$WORKFLOW"
[ "$status" -eq 0 ]
[ "$output" = "pr-review/stable" ]
[ "$output" = "pr-review/v1-stable" ]
run yq '.jobs.pr-review-mention.uses' "$WORKFLOW"
[ "$status" -eq 0 ]
[[ "$output" == *"/pr-review-mention-reusable.yml@pr-review-mention/v2-stable" ]]
Expand Down Expand Up @@ -161,3 +161,10 @@ ROLES=(dev-lead pr-auto-review pr-review pr-review-mention ci-failure-analyst)
|| { printf '%s\n' "$role: if: reaches repo state"; return 1; }
done
}

@test "pr-review pins the major-scoped v1-stable channel, not the legacy bare tag (#520)" {
run grep -E '/pr-review\.yml@' "$WORKFLOW"
[ "$status" -eq 0 ]
[[ "$output" =~ @pr-review/v1-stable[[:space:]]+#[[:space:]]*NOSONAR\(githubactions:S7637\)[[:space:]]+first-party[[:space:]]+channel[[:space:]]+ref ]]
[[ "$output" != *"DEFECTIVE PIN"* ]]
}
4 changes: 2 additions & 2 deletions .github/workflows/agent-ingress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,9 @@ jobs:
contents: read
pull-requests: write
checks: read
uses: petry-projects/.github-private/.github/workflows/pr-review.yml@pr-review/stable # NOSONAR(githubactions:S7637) first-party channel ref # DEFECTIVE PIN — see §5
uses: petry-projects/.github-private/.github/workflows/pr-review.yml@pr-review/v1-stable # NOSONAR(githubactions:S7637) first-party channel ref
with:
agent_ref: pr-review/stable
agent_ref: pr-review/v1-stable
pr_url: ${{ inputs.pr_url || '' }}
dry_run: ${{ inputs.dry_run || '' }}
force_review: ${{ inputs.force_review || '' }}
Expand Down
Loading