From 8117e038f140dd56074955b8d508d5ae7cc38a00 Mon Sep 17 00:00:00 2001 From: Parsa Hajiha Date: Mon, 15 Dec 2025 19:55:34 -0600 Subject: [PATCH] add CI workflow for running server tests --- .github/workflows/ci.yml | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..c75db42 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,40 @@ +name: CI — Run server tests + +on: + push: + branches: [main] + workflow_dispatch: + +jobs: + test-server: + name: Run Python tests (server) + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: "3.11" + + - name: Cache pip + uses: actions/cache@v4 + with: + path: ~/.cache/pip + key: ${{ runner.os }}-pip-${{ hashFiles('server/requirements.txt') }} + restore-keys: | + ${{ runner.os }}-pip- + + - name: Install server dependencies + run: | + python -m pip install --upgrade pip + pip install -r server/requirements.txt + + - name: Run server tests + working-directory: server + env: + PYTHONDONTWRITEBYTECODE: 1 + run: | + pytest -q