mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2026-03-31 01:21:28 +00:00
Tests: Add automated testing framework with coverage support
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
16
Makefile
16
Makefile
@ -1,10 +1,22 @@
|
||||
install:
|
||||
pip install -e .
|
||||
uv pip install -e ".[test]"
|
||||
|
||||
clean:
|
||||
rm -rf build dist *.egg-info
|
||||
rm -rf examples/*.ll examples/*.o
|
||||
rm -rf htmlcov .coverage
|
||||
|
||||
test:
|
||||
pytest tests/ -v --tb=short -m "not verifier"
|
||||
|
||||
test-cov:
|
||||
pytest tests/ -v --tb=short -m "not verifier" \
|
||||
--cov=pythonbpf --cov-report=term-missing --cov-report=html
|
||||
|
||||
test-verifier:
|
||||
@echo "NOTE: verifier tests require sudo and bpftool. Uses sudo .venv/bin/python3."
|
||||
pytest tests/test_verifier.py -v --tb=short -m verifier
|
||||
|
||||
all: clean install
|
||||
|
||||
.PHONY: all clean
|
||||
.PHONY: all clean install test test-cov test-verifier
|
||||
|
||||
Reference in New Issue
Block a user