-
Notifications
You must be signed in to change notification settings - Fork 1
41 lines (32 loc) · 881 Bytes
/
code_check.yml
File metadata and controls
41 lines (32 loc) · 881 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Python Code Check
on:
push:
# For manual triggering
workflow_dispatch:
permissions:
contents: read
jobs:
code_check:
runs-on: ubuntu-latest
env:
PYTHON_VERSION: 3.12
steps:
- name: Checkout git repo
uses: actions/checkout@v6
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v6
with:
python-version: "${{ env.PYTHON_VERSION }}"
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
pip install -r requirements.txt
pip install pylint
- name: Lint with pylint
env:
PYTHONPATH: ${{ github.workspace }}
run: |
pylint middleware
- name: Test with python unittest
run: |
python -m unittest discover -s middleware -p "test_*.py"