fix: add error handling for test step
Some checks failed
CI / test (push) Failing after 5s

This commit is contained in:
2026-02-02 04:20:33 +00:00
parent c957ef0267
commit 761f296ffd

View File

@@ -11,17 +11,23 @@ jobs:
git clone https://${{ gitea.server }}/${{ gitea.repository }} . git clone https://${{ gitea.server }}/${{ gitea.repository }} .
git checkout ${{ gitea.sha }} git checkout ${{ gitea.sha }}
- name: Python version - name: Install Python deps
run: python3 --version
- name: Install deps
run: | run: |
python3 -m pip install --upgrade pip python3 -m pip install --upgrade pip -q
python3 -m pip install pytest ruff python3 -m pip install pytest ruff -q
python3 -m pip install -e ".[dev]"
- name: Run tests - name: Run tests
run: python3 -m pytest tests/ -v --tb=short run: |
set +e
python3 -m pytest tests/ -v --tb=short
TEST_EXIT=$?
set -e
if [ $TEST_EXIT -ne 0 ]; then
echo "Tests failed with exit code $TEST_EXIT"
exit $TEST_EXIT
fi
echo "Tests passed"
- name: Run linting - name: Run linting
run: python3 -m ruff check i18n_key_sync/ tests/ || true run: |
python3 -m ruff check i18n_key_sync/ tests/ || echo "Linting had issues"