mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
31 lines
527 B
Makefile
31 lines
527 B
Makefile
T = $(sort $(wildcard *.t))
|
|
|
|
PROVE := $(shell command -v prove 2> /dev/null)
|
|
|
|
MAKEFLAGS = -j1
|
|
|
|
# IMPORTANT: `sh` should come somewhere AFTER `pytest`.
|
|
check: sh pytest
|
|
|
|
pytest:
|
|
cd .. && coverage run --append /usr/bin/pytest test
|
|
|
|
ifdef PROVE
|
|
sh:
|
|
prove .
|
|
else
|
|
sh: $(T)
|
|
endif
|
|
|
|
coverage:
|
|
cd .. && coverage report --include='aurweb/*'
|
|
cd .. && coverage xml --include='aurweb/*'
|
|
|
|
clean:
|
|
$(RM) -r test-results/
|
|
rm -f ../.coverage
|
|
|
|
$(T):
|
|
@echo "*** $@ ***"; $(SHELL) $@ -v
|
|
|
|
.PHONY: check coverage $(FOREIGN_TARGETS) clean $(T)
|