Skip to content

Commit 1f7f2ff

Browse files
committed
test: add pytest.yml
1 parent 449e6a5 commit 1f7f2ff

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

.github/workflows/pytest.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,22 +14,21 @@ jobs:
1414
python-version: ["3.13"]
1515
steps:
1616
- uses: actions/checkout@v3
17+
1718
- name: Set up Python ${{ matrix.python-version }}
1819
uses: actions/setup-python@v4
1920
with:
2021
python-version: ${{ matrix.python-version }}
22+
2123
- name: Install dependencies
2224
run: |
2325
python -m pip install --upgrade pip
24-
cd backend/src
25-
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
26-
if [ -f requirements-dev.txt ]; then pip install -r requirements-dev.txt; fi
26+
pip install -r backend/src/requirements.txt
27+
pip install -r backend/src/requirements-dev.txt
2728
2829
- name: Test with Pytest
29-
env:
30-
PYTHONPATH: ${{ github.workspace }}/backend/src
3130
run: |
32-
cat <<EOF > .env
31+
cat <<EOF > backend/src/.env
3332
DOMAIN=localhost
3433
FRONTEND_HOST=http://localhost:5173
3534
ENVIRONMENT=local
@@ -53,5 +52,5 @@ jobs:
5352
POSTGRES_USER=testuser
5453
POSTGRES_PASSWORD=testpassword
5554
EOF
56-
cd ../..
55+
5756
pytest --config-file=backend/pyproject.toml backend/tests

0 commit comments

Comments
 (0)