Skip to content
Merged
Changes from 6 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
10 changes: 9 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false # Allow previous workflows’ clean-up steps to complete

env:
TESTING_REPOSITORY: github/accessibility-scanner-testing

jobs:
test:
name: Test
Expand Down Expand Up @@ -74,7 +77,7 @@ jobs:
login_url: http://127.0.0.1:4000/
username: ${{ secrets.TEST_USERNAME }}
password: ${{ secrets.TEST_PASSWORD }}
repository: github/accessibility-scanner-testing
repository: ${{ env.TESTING_REPOSITORY }}
token: ${{ secrets.GH_TOKEN }}
cache_key: ${{ steps.cache_key.outputs.cache_key }}

Expand Down Expand Up @@ -110,6 +113,11 @@ jobs:
if [[ "$URL" == *"/pull/"* ]]; then
echo "Closing pull request: $URL"
gh pr close "$URL" || echo "Failed to close pull request: $URL"
branch="$(gh pr view "$URL" --json headRefName -q .headRefName || true)"
Comment thread
smockle marked this conversation as resolved.
if [[ -n "$branch" ]]; then
echo "Deleting branch: $branch"
git push "https://github.com/${{ env.TESTING_REPOSITORY }}" --delete "$branch" || echo "Failed to delete branch: $branch"
Comment thread
smockle marked this conversation as resolved.
Outdated
Comment thread
smockle marked this conversation as resolved.
Outdated
Comment thread
smockle marked this conversation as resolved.
Outdated
fi
elif [[ "$URL" == *"/issues/"* ]]; then
echo "Closing issue: $URL"
gh issue close "$URL" || echo "Failed to close issue: $URL"
Expand Down