-
Notifications
You must be signed in to change notification settings - Fork 1
43 lines (41 loc) · 1.1 KB
/
test-lint.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
# This workflow will install Python dependencies, run tests, lint, and build docs
# This run for every pull request
name: Tests and Lint
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build:
timeout-minutes: 10
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.9"
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip setuptools black mypy types-requests numpy
- name: Black Formatting
run: |
python3 -m black . --check
- name: Lint with mypy
run: |
python3 -m mypy src/neospy/
- name: Build neospy
run: |
python3 -m pip install '.[dev]' -v
- name: Test with pytest
run: |
python3 -m pytest --cov-report term-missing --cov=neospy
- name: Test with cargo
run: |
cargo test