From 0dd97318a23a138e38b7a376b062334f8b3a010e Mon Sep 17 00:00:00 2001 From: 7000pctAUTO Date: Mon, 2 Feb 2026 20:10:32 +0000 Subject: [PATCH] fix: resolve CI workflow failures - corrected lint paths and package name --- .gitea/workflows/ci.yml | 65 ++++++++++++++++++++++++++++++++++++----- 1 file changed, 57 insertions(+), 8 deletions(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 47c38ee..10bdf3b 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -2,27 +2,76 @@ name: CI on: push: - branches: [main] + branches: [main, master] pull_request: - branches: [main] + branches: [main, master] jobs: test: runs-on: ubuntu-latest + strategy: + matrix: + python-version: ["3.10", "3.11", "3.12"] + + steps: + - 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 tests + run: | + python -m pytest tests/ -v --tb=short + + lint: + runs-on: ubuntu-latest + steps: - uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.11' + python-version: "3.12" - name: Install dependencies run: | - pip install -e ".[dev]" + python -m pip install --upgrade pip + pip install ruff + pip install -e . - - name: Run tests - run: pytest tests/ -v + - name: Run linter + run: | + ruff check src/ tests/ - - name: Run linting - run: ruff check src/ tests/ + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.12" + + - name: Install build dependencies + run: | + python -m pip install --upgrade pip + pip install build + + - name: Build package + run: | + python -m build + + - name: Verify installation + run: | + pip install dist/openapi_mock_generator-0.1.0-py3-none-any.whl + python -c "import src; from src.__main__ import main; print('Package imported successfully')"