forked from DataDog/guarddog
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
26 lines (18 loc) · 977 Bytes
/
Makefile
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
.PHONY: test test-semgrep-rules test-metadata-rules test-core docs
test: test-semgrep-rules test-metadata-rules test-core coverage-report
type-check:
mypy --install-types --non-interactive guarddog
lint:
flake8 guarddog --count --select=E9,F63,F7,F82 --show-source --statistics --exclude tests/analyzer/sourcecode,tests/analyzer/metadata/resources,evaluator/data
flake8 guarddog --count --max-line-length=120 --statistics --exclude tests/analyzer/sourcecode,tests/analyzer/metadata/resources,evaluator/data --ignore=E203,W503
test-semgrep-rules:
semgrep --metrics off --quiet --test --config guarddog/analyzer/sourcecode tests/analyzer/sourcecode
test-metadata-rules:
COVERAGE_FILE=.coverage_metadata coverage run -m pytest tests/analyzer/metadata
test-core:
COVERAGE_FILE=.coverage_core coverage run -m pytest tests/core
coverage-report:
coverage combine .coverage_metadata .coverage_core
coverage report
docs:
python scripts/generate-rules-docs.py README.md