-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (55 loc) · 1.58 KB
/
code-checks.yml
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: 'Code Checks'
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
permissions:
contents: read
pull-requests: read
concurrency:
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true
jobs:
lint-python:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python 3.12 with Poetry
uses: ./.github/actions/setup-python-deps
- name: Run Pylint
run: poetry run pylint -f colorized --score y ./app
- name: Run isort
run: poetry run isort -c ./app
- name: Run flake8
run: poetry run flake8 --show-source --statistics ./app
test-python:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python 3.12 with Poetry
uses: ./.github/actions/setup-python-deps
- name: Run Pytest
run: poetry run pytest --color=yes --doctest-modules --junitxml=junit/test-results.xml ./app/tests
- name: Upload pytest results
uses: actions/upload-artifact@v4
with:
name: pytest-results
path: junit/test-results.xml
if: ${{ always() }}
lint-typescript:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install dependencies
run: bun install --frozen-lockfile
- name: ESLint
run: bun run lint --color