Skip to content

Commit

Permalink
Testing: Remove release-patch-setup and release-patch-test; fix #6541
Browse files Browse the repository at this point in the history
  • Loading branch information
rdimaio authored and bari12 committed Mar 15, 2024
1 parent 145fac0 commit 759c19a
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 199 deletions.
75 changes: 0 additions & 75 deletions .github/workflows/autotest.yml
Expand Up @@ -170,78 +170,3 @@ jobs:
echo "images=$IMAGES" >> $GITHUB_OUTPUT
- name: Run test with cfg
run: 'echo ''{"matrix": ${{ toJson(matrix.cfg) }}, "images": ${{ steps.images.outputs.images }} }'' | ./tools/test/run_tests.py'
release-patch-setup:
if: |
github.event_name == 'pull_request' && !startsWith(github.event.pull_request.base.ref, 'release') && !startsWith(github.event.pull_request.head.ref, 'feature')
&& (github.repository_owner == 'rucio' || github.event_name != 'schedule')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Update pip
run: python3 -m pip install -U pip setuptools
- name: Install python requirements for matrix_parser.py
run: python3 -m pip install -U sh PyYAML
- name: Grab latest release branch
id: grabrelease
run: echo "release_branch=$(echo "${{ github.event.repository.branches_url }}" | ./tools/github/workflow/grabrelease.py)" >> $GITHUB_OUTPUT
- name: Fetch pull request commit range
id: prcommits
run: echo "source_commits=$(echo "${{ github.event.pull_request.commits_url }}" | ./tools/github/workflow/prcommits.py)" >> $GITHUB_OUTPUT
- name: Test cherry-picking pull request changes
run: |
echo '{
"source_remote_name": "${{ github.actor }}",
"source_remote": "${{ github.event.pull_request.head.repo.full_name }}",
"source_commits": "${{ steps.prcommits.outputs.source_commits }}",
"target_remote": "${{ github.event.pull_request.base.repo.full_name }}",
"target_branch": "${{ steps.grabrelease.outputs.release_branch }}"
}' | ./tools/github/workflow/mergetest.py
- name: Identify Matrix
id: matrix
run: echo "matrix=$(./tools/test/matrix_parser.py < ./etc/docker/test/matrix.yml)" >> $GITHUB_OUTPUT
outputs:
release_branch: ${{ steps.grabrelease.outputs.release_branch }}
source_commits: ${{ steps.prcommits.outputs.source_commits }}
matrix: ${{ steps.matrix.outputs.matrix }}
release-patch-test:
needs: release-patch-setup
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
cfg: ${{ fromJson(needs.release-patch-setup.outputs.matrix) }}
steps:
- uses: actions/checkout@v4
- name: Update pip
run: python3 -m pip install -U pip setuptools
- name: Install python requirements for mergetest.py
run: python3 -m pip install -U sh
- name: Cherry-pick pull request changes
run: |
echo '{
"source_remote_name": "${{ github.actor }}",
"source_remote": "${{ github.event.pull_request.head.repo.full_name }}",
"source_commits": "${{ needs.release-patch-setup.outputs.source_commits }}",
"target_remote": "${{ github.event.pull_request.base.repo.full_name }}",
"target_branch": "${{ needs.release-patch-setup.outputs.release_branch }}"
}' | ./tools/github/workflow/mergetest.py
- name: Build images
id: images
shell: bash
run: |
docker login https://ghcr.io -u ${{ github.actor }} -p ${{ secrets.GITHUB_TOKEN }}
i=0; until [ "$i" -ge 3 ]; do
IMAGES=$(echo '${{ toJson(matrix.cfg) }}' | DOCKER_BUILDKIT=1 ./tools/test/build_images.py \
--cache-repo ghcr.io/${{ github.repository }} \
--branch "${{ needs.release-patch-setup.outputs.release_branch }}" ./etc/docker/test || echo "")
if [[ -n $IMAGES ]]; then break;
else
i=$((i+1)); sleep 5;
echo "::warning::Building images failed, retrying…"
fi
done
docker logout https://ghcr.io
if [[ -z "$IMAGES" ]]; then echo "::error::Building images failed ultimately"; exit 1; fi
echo "images=$IMAGES" >> $GITHUB_OUTPUT
- name: Run test with cfg
run: 'echo ''{"matrix": ${{ toJson(matrix.cfg) }}, "images": ${{ steps.images.outputs.images }} }'' | ./tools/test/run_tests.py'
83 changes: 0 additions & 83 deletions tools/github/workflow/mergetest.py

This file was deleted.

41 changes: 0 additions & 41 deletions tools/github/workflow/prcommits.py

This file was deleted.

0 comments on commit 759c19a

Please sign in to comment.