Skip to content

Commit bc92dcc

Browse files
committed
ci(e2e): use ok-to-test action for permission checks
Replace inline permission check script with the standalone pipelines-as-code/ok-to-test GitHub Action. Signed-off-by: Zaki Shaikh <zashaikh@redhat.com> Assisted-by: Claude Opus 4.6 (via Claude Code)
1 parent f8e4343 commit bc92dcc

2 files changed

Lines changed: 2 additions & 213 deletions

File tree

.github/scripts/check-pr-permissions.js

Lines changed: 0 additions & 206 deletions
This file was deleted.

.github/workflows/e2e.yaml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ on:
2525
- ".github/workflows/**"
2626
- "test/testdata/**"
2727
- "vendor/**"
28-
- ".github/scripts/**"
2928

3029
jobs:
3130
e2e-tests:
@@ -127,15 +126,11 @@ jobs:
127126
with:
128127
ref: ${{ inputs.target_ref || github.event.pull_request.head.sha || github.sha }}
129128

130-
# Step to check PR author's org membership and repo permissions.
131-
# This step will fail the job if checks do not pass, skipping subsequent steps.
132129
- name: Check user permissions on PRs
133130
if: github.event_name == 'pull_request_target'
134-
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8
131+
uses: pipelines-as-code/ok-to-test@d8b77eadfab387739a82c1ac8e1c3ccff4a594e7 # v1
135132
with:
136-
script: |
137-
const script = require('./.github/scripts/check-pr-permissions.js')
138-
await script({github, context, core})
133+
team-slugs: ${{ env.TARGET_TEAM_SLUGS }}
139134

140135
- uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6
141136
with:

0 commit comments

Comments
 (0)