Files
code-pattern-search-cli/.gitea/workflows/ci.yml
7000pctAUTO 68e2679441
Some checks failed
CI / test (3.11) (push) Has been cancelled
CI / test (3.9) (push) Has been cancelled
CI / build (push) Has been cancelled
CI / test (3.10) (push) Has been cancelled
Add CI workflow file
2026-02-02 18:29:25 +00:00

53 lines
1.3 KiB
YAML

name: CI
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11']
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: Lint with flake8
run: |
pip install flake8
flake8 src/ tests/ --max-line-length=100 --ignore=E501,W503
- name: Run tests
run: |
pip install pytest pytest-cov
pytest tests/ -v --tb=short
build:
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install build
python -m build
- name: Verify build
run: |
pip install dist/*.whl
pip install requests ghapi
python -c "import code_pattern_search_cli; print('Build successful')"