Skip to content

Commit

Permalink
fix test action
Browse files Browse the repository at this point in the history
  • Loading branch information
ilius committed Sep 2, 2024
1 parent acdbede commit c2b3db0
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,23 @@ jobs:
run: rm -rf /home/runner/.cache/pyglossary/test || true
- name: Run tests
run: |
set -o pipefail
set -x
set +e
export NO_CLEANUP=1
set -o pipefail
bash ./scripts/test.sh 2>&1 | tee test.out
mkdir upload
cp test.out upload/
grep -o "'/tmp/pyglossary/[^']*'" test.out | sed "s/'//g" | xargs '-I{}' cp '{}' upload
ls -l upload
STATUS=$?
set +o pipefail
ARTIFACTS=test-artifacts
mkdir $ARTIFACTS
cp test.out $ARTIFACTS
grep -o "'/tmp/pyglossary/[^']*'" test.out | sed "s/'//g" | xargs '-I{}' cp '{}' $ARTIFACTS
ls -l $ARTIFACTS
set -e
exit $STATUS
- name: Upload test artifacts
if: always()
uses: actions/upload-artifact@v4
with:
name: upload
path: upload/
name: test-artifacts-{{ github.sha }}-py${{ matrix.python-version }}
path: test-artifacts

0 comments on commit c2b3db0

Please sign in to comment.