forked from lundberg/respx
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Taskfile.yaml
64 lines (55 loc) · 1.41 KB
/
Taskfile.yaml
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
57
58
59
60
61
62
63
64
version: "3"
tasks:
default:
cmds: [task: all]
all:
desc: Run test suite, mypy & linting
label: all -- [nox options]
silent: true
deps: [tools]
cmds:
- .venv/bin/nox -k "test + mypy" {{.CLI_ARGS | default "-R"}}
- task: lint
test:
desc: Run test suite against latest python
label: test -- [pytest options]
silent: true
deps: [tools]
cmds: [".venv/bin/nox -R -s test-3.11 -- {{.CLI_ARGS}}"]
mypy:
desc: Statically type check python files
silent: true
deps: [tools]
cmds: [.venv/bin/nox -R -s mypy]
lint:
desc: Lint project files
silent: true
deps: [tools]
cmds: [.venv/bin/pre-commit run --all-files]
docs:
desc: Start docs server, in watch mode
silent: true
deps: [tools]
cmds: [.venv/bin/nox -R -s docs -- serve]
reset:
desc: Delete environment and artifacts
silent: true
cmds:
- echo Deleting environment and artifacts ...
- rm -rf \
.venv .nox .mypy_cache .pytest_cache respx.egg-info .coverage coverage.xml
tools:
internal: true
silent: true
run: once
deps: [venv]
cmds: [.venv/bin/python -m pip install nox pre-commit]
status:
- test -f .venv/bin/nox
- test -f .venv/bin/pre-commit
venv:
internal: true
silent: true
run: once
cmds: [python -m venv --copies --upgrade-deps .venv > /dev/null]
status: [test -d .venv]