Skip to content

Commit

Permalink
Add GitHub Actions workflows for tests and linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Pabloo22 committed Feb 12, 2024
1 parent f078fa5 commit 221fc95
Showing 1 changed file with 61 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Tests

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
tests:

runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest, windows-latest]
python-version: ["3.11"]

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
pip install --upgrade pip
pip install poetry=1.7
poetry install --with dev
- name: Run tests
run: poetry run pytest -v

lint:

runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.11

- name: Install dependencies
run: |
pip install --upgrade pip
pip install poetry==1.7
poetry install
- name: Run flake8
run: |
poetry run flake8
- name: Run mypy
run: |
poetry run mypy

0 comments on commit 221fc95

Please sign in to comment.