-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
48 lines (36 loc) · 1.33 KB
/
Makefile
File metadata and controls
48 lines (36 loc) · 1.33 KB
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
.PHONY: help init test test-cov-report lint lint-fix lint-diff format format-check
help:
$(info ${HELP_MESSAGE})
@exit 0
init:
pip install --upgrade -r dev-requirements.txt
test:
pytest --cov functions --cov layers --cov-report term-missing --cov-fail-under 95 -n auto tests/
test-cov-report:
pytest --cov functions --cov layers --cov-report term-missing --cov-report html -n auto tests/
xdg-open htmlcov/index.html &> /dev/null || open htmlcov/index.html &> /dev/null || true
lint:
ruff check functions tests layers/python
lint-fix:
ruff check --fix functions tests layers/python
lint-diff:
ruff check --diff functions tests layers/python
format:
black functions tests layers/python
format-check:
black --check functions tests layers/python
build:
sam build
define HELP_MESSAGE
Usage: $ make [TARGETS]
TARGETS
init Initialize and install the requirements and dev-requirements for this project.
test Run the Unit tests.
test-cov-report Run the Unit tests and generate a coverage report.
lint Run the linter.
lint-diff Show the diff of the linter.
lint-fix Run the linter and fix the issues.
format Format the code using Black.
format-check Check the code formatting using Black.
build Builds the project using AWS SAM.
endef