ci: add memory leak detection workflow
All checks were successful
CI / Lint & Format (push) Successful in 18s
CI / Security Scan (push) Successful in 22s
CI / Memory Leak Check (push) Successful in 21s
CI / Tests (push) Successful in 1m16s

This commit is contained in:
Username
2025-12-24 00:19:33 +01:00
parent 51af8fd2f8
commit fef5eac1b5
2 changed files with 195 additions and 0 deletions

View File

@@ -110,3 +110,25 @@ jobs:
pytest tests/ --cov=app --cov-report=term-missing --cov-fail-under=70 || \
echo "::warning::Coverage below 70%"
continue-on-error: true
memory:
name: Memory Leak Check
runs-on: ubuntu-latest
needs: [lint]
container:
image: python:3.11-slim
steps:
- name: Setup and checkout
run: |
apt-get update -qq && apt-get install -yqq --no-install-recommends git >/dev/null
git clone --depth 1 --branch "${GITHUB_REF_NAME}" \
"https://oauth2:${{ github.token }}@${GITHUB_SERVER_URL#https://}/${GITHUB_REPOSITORY}.git" .
- name: Install dependencies
run: |
pip install -q -r requirements.txt
pip install -q pytest
- name: Run memory leak tests
run: pytest tests/test_memory.py -v --tb=short