Skip to content

Commit

Permalink
Add GH CI workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
simahawk committed Sep 20, 2024
1 parent e819ab9 commit ea53560
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: CI

on:
push:
branches: ["master"]
pull_request:

jobs:
# TODO
# pre-commit:
# runs-on: ubuntu-22.04
# steps:
# - uses: actions/checkout@v2
# - uses: actions/setup-python@v2
# with:
# python-version: "3.11"
# - uses: pre-commit/[email protected]
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- PYTHON_VERSION: "3.9"
os: ubuntu-latest
- PYTHON_VERSION: "3.10"
os: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: ${{matrix.PYTHON_VERSION}}
- name: Configure TOX
run: |
pip install pip --upgrade
pip install tox codecov tox-gh-actions wheel
- name: Generate Report
run: |
pip install coverage
pip install .[test]
coverage run -m unittest
- name: Upload Coverage to Codecov
uses: codecov/codecov-action@v3
4 changes: 4 additions & 0 deletions .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
name: PYPI Publish

on:

workflow_run:
# Depend on the CI workflow
workflows: ["CI"]
pull_request:
push:
branches:
Expand Down

0 comments on commit ea53560

Please sign in to comment.