Skip to content

Test Matrix

Test Matrix #349

Workflow file for this run

name: Test Matrix
on:
schedule:
# Run nightly comprehensive testing at 2 AM UTC
- cron: '0 2 * * *'
workflow_dispatch:
# Allow manual triggering
push:
branches: [main]
paths:
- 'src/**'
- 'tests/**'
- 'pyproject.toml'
- 'requirements*.txt'
- 'uv.lock'
- 'Makefile'
- 'makefiles/**'
- '.github/workflows/test-matrix.yml'
# Only run on main branch for comprehensive testing
jobs:
get-config:
name: Get Configuration
uses: ./.github/workflows/shared-config.yml
unit-tests:
name: Unit Tests
needs: get-config
permissions:
contents: read
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest] # Disabled windows-latest, macos-latest for now
# Dynamic matrix from config with static fallback for act/dry-run
# Update static list when adding new Python versions (currently 3.10-3.14)
python-version: ${{ fromJSON(needs.get-config.outputs.python-versions || '["3.10", "3.11", "3.12", "3.13", "3.14"]') }}
uses: ./.github/workflows/reusable-test.yml
with:
test-type: unit
python-version: ${{ matrix.python-version }}
os: ${{ matrix.os }}
default-python-version: ${{ needs.get-config.outputs.default-python-version }}
continue-on-error: true # TODO: Remove once tests are stable
aws-region: ${{ needs.get-config.outputs.aws-region }}
aws-access-key: ${{ needs.get-config.outputs.aws-access-key }}
aws-secret-key: ${{ needs.get-config.outputs.aws-secret-key }}
environment: ${{ needs.get-config.outputs.environment }}
testing-flag: ${{ needs.get-config.outputs.testing-flag }}
integration-tests:
name: Integration Tests
needs: [get-config, unit-tests]
permissions:
contents: read
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest] # Disabled windows-latest, macos-latest for now
# Dynamic matrix from config with static fallback for act/dry-run
# Update static list when adding new Python versions (currently 3.10-3.14)
python-version: ${{ fromJSON(needs.get-config.outputs.python-versions || '["3.10", "3.11", "3.12", "3.13", "3.14"]') }}
uses: ./.github/workflows/reusable-test.yml
with:
test-type: integration
python-version: ${{ matrix.python-version }}
os: ${{ matrix.os }}
default-python-version: ${{ needs.get-config.outputs.default-python-version }}
continue-on-error: true # TODO: Remove once tests are stable
aws-region: ${{ needs.get-config.outputs.aws-region }}
aws-access-key: ${{ needs.get-config.outputs.aws-access-key }}
aws-secret-key: ${{ needs.get-config.outputs.aws-secret-key }}
environment: ${{ needs.get-config.outputs.environment }}
testing-flag: ${{ needs.get-config.outputs.testing-flag }}
e2e-tests:
name: End-to-End Tests
needs: [get-config, unit-tests, integration-tests]
permissions:
contents: read
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest] # Disabled windows-latest, macos-latest for now
# Dynamic matrix from config with static fallback for act/dry-run
# Update static list when adding new Python versions (currently 3.10-3.14)
python-version: ${{ fromJSON(needs.get-config.outputs.python-versions || '["3.10", "3.11", "3.12", "3.13", "3.14"]') }}
uses: ./.github/workflows/reusable-test.yml
with:
test-type: e2e
python-version: ${{ matrix.python-version }}
os: ${{ matrix.os }}
default-python-version: ${{ needs.get-config.outputs.default-python-version }}
continue-on-error: true # TODO: Remove once tests are stable
aws-region: ${{ needs.get-config.outputs.aws-region }}
aws-access-key: ${{ needs.get-config.outputs.aws-access-key }}
aws-secret-key: ${{ needs.get-config.outputs.aws-secret-key }}
environment: ${{ needs.get-config.outputs.environment }}
testing-flag: ${{ needs.get-config.outputs.testing-flag }}
test-summary:
name: Test Summary
runs-on: ubuntu-latest
needs: [unit-tests, integration-tests, e2e-tests]
if: always()
permissions:
contents: read
steps:
- name: Download all test results
uses: actions/download-artifact@v4
with:
path: test-results/
- name: Display test summary
run: |
# Count test result files
UNIT_RESULTS=$(find test-results/ -name "*unit.xml" | wc -l)
INTEGRATION_RESULTS=$(find test-results/ -name "*integration.xml" | wc -l)
{
echo "## Test Matrix Results"
echo ""
echo "- Unit test configurations: $UNIT_RESULTS"
echo "- Integration test configurations: $INTEGRATION_RESULTS"
echo ""
echo "### Test Result Files:"
} >> "$GITHUB_STEP_SUMMARY"
find test-results/ -name "*.xml" | sort >> "$GITHUB_STEP_SUMMARY"