-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathMakefile
More file actions
43 lines (30 loc) · 951 Bytes
/
Makefile
File metadata and controls
43 lines (30 loc) · 951 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
42
43
.PHONY: docs tests
# Dependencies
dependencies:
poetry install
# Tests
unit-tests:
poetry run py.test --cov=pycaprio --cov-branch --cov-fail-under=90 --cov-report=xml:unit-coverage.xml tests/unit_tests
integ-tests:
poetry run py.test -s --cov=pycaprio --cov-branch --cov-fail-under=70 --cov-report=xml:integration-coverage.xml tests/integ_tests
tests: unit-tests integ-tests
format:
poetry run ruff format pycaprio --line-length=120
poetry run ruff format tests --line-length=120
# Static analysis/linting
lint:
poetry run ruff check pycaprio --line-length=120 --fix
poetry run ruff check tests --line-length=120 --fix --ignore=E722
# Docs
docs:
poetry run mkdocs serve
# Building and publishing
build: unit-tests lint
poetry build
publish: build
poetry publish
# CI
ci-publish:
poetry publish --build --username "${PYPI_USERNAME}" --password "${PYPI_PASSWORD}" --no-interaction
ci-bump-version:
poetry run bump2version patch