Skip to content

Commit

Permalink
👷 Add tox to ci workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
veit committed Apr 28, 2024
1 parent 16a2e65 commit 2e029be
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 23 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: CI

on:
pull_request:
push:
branches: [main]

env:
FORCE_COLOR: "1"
PIP_DISABLE_PIP_VERSION_CHECK: "1"
PIP_NO_PYTHON_VERSION_WARNING: "1"

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
- uses: actions/cache@v3
with:
path: ~/.cache/pre-commit
key: pre-commit|${{ env.pythonLocation }}|${{ hashFiles('.pre-commit-config.yaml') }}
- uses: pre-commit/action@v3.0.0

tests:

name: Tests on ${{ matrix.python-version }}

strategy:
fail-fast: false
matrix:
python-version:
- "3.8"
- "3.9"
- "3.10"
- "3.11"
- "3.12"

steps:
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python }}
- name: Install tox
run: python -Im pip install tox
- name: Run tests for "${{ matrix.python }}"
run: python -Im tox
23 changes: 0 additions & 23 deletions .github/workflows/pre-commit.yml

This file was deleted.

0 comments on commit 2e029be

Please sign in to comment.