You've already forked snikket-web-portal
Add a bunch of CI tests for the code
This commit is contained in:
50
.github/workflows/main.yaml
vendored
Normal file
50
.github/workflows/main.yaml
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
name: Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- "release/*"
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
- "release/*"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
mypy:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
name: 'typecheck: mypy'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.9'
|
||||
- name: Install
|
||||
run: |
|
||||
set -euo pipefail
|
||||
pip install mypy
|
||||
pip install -r requirements.txt
|
||||
- name: Typecheck
|
||||
run: |
|
||||
python -m mypy --config mypy.ini -p snikket_web
|
||||
|
||||
linting:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
name: 'lint: flake8'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.9'
|
||||
- name: Install
|
||||
run: |
|
||||
set -euo pipefail
|
||||
pip install flake8
|
||||
- name: Linting
|
||||
run: |
|
||||
python -m flake8 snikket_web
|
||||
Reference in New Issue
Block a user