ci: add memory leak detection workflow
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user