From ad64f168a1017f0cfed5722c1ab23f7fae497d84 Mon Sep 17 00:00:00 2001 From: cloudix_mcp_server Date: Fri, 12 Jun 2026 20:19:29 -0400 Subject: [PATCH] feat(ci): add PR workflow with tests + integration tests --- .gitea/workflows/pr.yaml | 42 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 .gitea/workflows/pr.yaml diff --git a/.gitea/workflows/pr.yaml b/.gitea/workflows/pr.yaml new file mode 100644 index 0000000..7562152 --- /dev/null +++ b/.gitea/workflows/pr.yaml @@ -0,0 +1,42 @@ +name: PR Checks + +on: + pull_request: + branches: [main] + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6 + - uses: actions/setup-python@a309ff8b426b258ec0a6e2f7b8a30f9f6689405 # v6 + with: + python-version: "3.14" + - name: Install dependencies + run: pip install -r requirements.txt pytest + - name: Run unit tests + run: python -m pytest tests/ -v --ignore=tests/test_integration.py + + integration-test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6 + - name: Start Qdrant + run: docker run -d --name qdrant --network "container:$(hostname)" docker.io/qdrant/qdrant:latest + - name: Wait for Qdrant + run: | + for i in $(seq 1 30); do + curl -s http://localhost:6333/healthz && echo "QDRANT ready" && break + echo "Waiting for Qdrant... ($i/30)" + sleep 1 + done + - uses: actions/setup-python@a309ff8b426b258ec0a6e2f7b8a30f9f6689405 # v6 + with: + python-version: "3.14" + - name: Install dependencies + run: pip install -r requirements.txt pytest + - name: Run integration tests + run: python -m pytest tests/test_integration.py -v + env: + QDRANT_URL: http://localhost:6333 + COLLECTION_NAME: test_mcp_maildir