Python 3.14 is still in development (alpha/beta) and causing cocotb simulation tests to fail. The cocotb library and its dependencies are not yet fully compatible with Python 3.14. Tests work correctly on Python 3.10-3.13, which aligns with the project's requirements. Co-authored-by: arnavsacheti <36746504+arnavsacheti@users.noreply.github.com>
50 lines
1.1 KiB
YAML
50 lines
1.1 KiB
YAML
name: Test
|
|
|
|
on:
|
|
push:
|
|
branches: [ main ]
|
|
pull_request:
|
|
branches: [ main ]
|
|
workflow_dispatch:
|
|
workflow_call:
|
|
schedule:
|
|
# Run weekly on Monday at 00:00 UTC
|
|
- cron: '0 0 * * 1'
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
strategy:
|
|
matrix:
|
|
python-version: ['3.10', '3.11', '3.12', '3.13']
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Set up uv
|
|
uses: astral-sh/setup-uv@v3
|
|
with:
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
- name: Install Verilator
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y verilator
|
|
verilator --version
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
uv sync --all-extras --group test
|
|
|
|
- name: Run tests
|
|
run: uv run pytest tests/ -v --cov=peakrdl_busdecoder --cov-report=xml --cov-report=term
|
|
|
|
- name: Upload coverage to Codecov
|
|
uses: codecov/codecov-action@v4
|
|
if: matrix.python-version == '3.12'
|
|
with:
|
|
file: ./coverage.xml
|
|
fail_ci_if_error: false
|