Skip to content

Commit

Permalink
add tox checks to ci
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinsung committed Jun 16, 2023
1 parent 3454a81 commit bb9ef61
Show file tree
Hide file tree
Showing 2 changed files with 95 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
# This file is autogenerated by maturin v1.0.1
# To update, run
#
# maturin generate-ci github
#
name: CI
name: build-and-release

on:
push:
branches:
- main
- master
tags:
- '*'
pull_request:
Expand Down
94 changes: 94 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
name: check

on:
push:
branches:
- main
tags:
- '*'
pull_request:
workflow_dispatch:

permissions:
contents: read

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.8, 3.9, '3.10', '3.11']
include:
- os: macos-latest
python-version: 3.8
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox
- name: Test using tox environment
shell: bash
run: |
tox run -e py${{ matrix.python-version }}
type:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.11'
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Run type check
run: tox run -e type
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.11'
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Run type check
run: tox run -e lint
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.11'
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Run type check
run: tox run -e format
coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.11'
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: Run type check
run: tox run -e coverage

0 comments on commit bb9ef61

Please sign in to comment.