Add GitHub Actions workflow for automated testing and setup
This commit is contained in:
parent
34f790ca18
commit
a8103af866
30
.gitea/workflows/run_tests.yml
Normal file
30
.gitea/workflows/run_tests.yml
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
name: Build Simulation and Test
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
tests:
|
||||||
|
name: Run All Tests
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Install uv
|
||||||
|
uses: astral-sh/setup-uv@v5
|
||||||
|
with:
|
||||||
|
enable-cache: true
|
||||||
|
cache-dependency-glob: "uv.lock"
|
||||||
|
|
||||||
|
- name: "Set up Python"
|
||||||
|
uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version-file: "pyproject.toml"
|
||||||
|
|
||||||
|
- name: Install the project
|
||||||
|
run: uv sync --locked --all-extras --dev
|
||||||
|
|
||||||
|
- name: Run tests
|
||||||
|
run: uv run pytest tests.py --doctest-modules --junitxml=junit/test-results.xml --cov=com --cov-report=xml --cov-report=html
|
||||||
Loading…
x
Reference in New Issue
Block a user