Skip to content

Commit

Permalink
add github pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
dec1 committed May 9, 2024
1 parent dc99707 commit 1db4d47
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Python CI

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
build-and-test:
runs-on: ubuntu-latest

steps:
- name: Check out the repository
uses: actions/checkout@v3

- name: Set up Python 3.12
uses: actions/setup-python@v4
with:
python-version: '3.12'

- name: Set up dependencies
run: |
cd prj/script
./venv_create.sh
cd ../..
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest mypy pylint
- name: Run tests with pytest
run: ./prj/script/venv/bin/pytest test/

- name: Run type checking with mypy
run: ./prj/script/venv/bin/mypy --check-untyped-defs -p test -p src

- name: Run linter with pylint
run: ./prj/script/venv/bin/python -m pylint src test

0 comments on commit 1db4d47

Please sign in to comment.