mirror of
https://github.com/velocitatem/PHANTOM.git
synced 2026-05-31 08:33:36 +00:00
32 lines
832 B
YAML
32 lines
832 B
YAML
name: Run Tests
|
|
on:
|
|
push:
|
|
paths:
|
|
- 'experiments/**'
|
|
- 'backend/**'
|
|
- 'requirements.txt'
|
|
- '.github/workflows/pytest.yml'
|
|
pull_request:
|
|
paths:
|
|
- 'experiments/**'
|
|
- 'backend/**'
|
|
- 'requirements.txt'
|
|
- '.github/workflows/pytest.yml'
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: '3.13'
|
|
cache: 'pip'
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m venv .venv
|
|
.venv/bin/pip install --upgrade pip
|
|
.venv/bin/pip install -r requirements.txt
|
|
- name: Run tests
|
|
run: .venv/bin/pytest -v
|