From 4b7663a9476a5abdfbac393fe3825dc8863165b7 Mon Sep 17 00:00:00 2001 From: Oscar V Date: Fri, 3 Apr 2026 10:24:04 -0700 Subject: [PATCH] ci: replace template validation with proper test workflow --- .github/workflows/ci.yml | 78 +++++++++++++++++++++++----------------- 1 file changed, 45 insertions(+), 33 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3d7b5ff..1a60a6c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,43 +1,55 @@ -name: Template Validation +name: CI on: push: - branches: [ main ] + branches: [main] pull_request: - branches: [ main ] + branches: [main] jobs: + test: + name: Test Python ${{ matrix.python-version }} + runs-on: ubuntu-latest + strategy: + matrix: + python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -e ".[dev]" + + - name: Run linting + run: ruff check src/ tests/ + + - name: Run type checking + run: mypy src/ + + - name: Run tests + run: pytest --cov=src/aiproxyguard --cov-report=term-missing + validate: - name: Validate Template Files + name: Validate Files runs-on: ubuntu-latest steps: - - name: Checkout code - uses: actions/checkout@v6 - - - name: Check required files exist - run: | - test -f LICENSE - test -f README.md - test -f CONTRIBUTING.md - test -f SECURITY.md - test -f CODE_OF_CONDUCT.md - test -f .clabot - echo "All required template files present" - - - name: Validate markdown files - uses: DavidAnson/markdownlint-cli2-action@v23 - with: - globs: '**/*.md' - config: | - { - "default": true, - "MD013": false, - "MD033": false, - "MD041": false - } - continue-on-error: true - - - name: Check for placeholder text - run: | - echo "Note: Remember to replace [Project Name] and other placeholders when using this template" + - name: Checkout code + uses: actions/checkout@v4 + + - name: Check required files exist + run: | + test -f LICENSE + test -f README.md + test -f CONTRIBUTING.md + test -f SECURITY.md + test -f CODE_OF_CONDUCT.md + echo "All required files present"