Files
NexQuant/.github/workflows/scheduled-tests.yml
T
TPTBusiness cb6cbd2bfc ci: add dependabot, conventional commits check, and scheduled weekly tests
- dependabot.yml: weekly auto-PRs for pip and github-actions deps
  (major version bumps ignored, reviewed manually)
- conventional-commits.yml: blocks PRs with non-conforming titles;
  warns on individual commits (required for release-please changelogs)
- scheduled-tests.yml: weekly pytest run on py3.10+3.11, plus
  dependency vulnerability audit via safety

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-18 08:35:19 +02:00

69 lines
1.7 KiB
YAML

name: Scheduled Tests
on:
schedule:
# Every Monday at 07:00 UTC
- cron: "0 7 * * 1"
workflow_dispatch: # Allow manual trigger
permissions:
contents: read
jobs:
test:
name: Weekly Test Run (Python ${{ matrix.python-version }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
cache: "pip"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[test]" || pip install -r requirements.txt
pip install pytest pytest-cov
- name: Run tests
run: |
pytest test/backtesting/ -v --tb=short --durations=10
- name: Upload results on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-results-py${{ matrix.python-version }}
path: |
.pytest_cache/
retention-days: 7
dependency-audit:
name: Dependency Audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.10"
cache: "pip"
- name: Install safety
run: pip install safety
- name: Check for known vulnerabilities
run: |
echo "=== Weekly dependency vulnerability scan ==="
safety check -r requirements.txt --json || {
echo "::warning::Vulnerabilities found — review and update dependencies"
exit 0
}