mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 22:16:16 +02:00
Create notion of "test group", use for local overlay store
This commit is contained in:
parent
1dcb782651
commit
97deb00cbc
3 changed files with 17 additions and 7 deletions
|
@ -10,6 +10,7 @@ bin-scripts :=
|
|||
noinst-scripts :=
|
||||
man-pages :=
|
||||
install-tests :=
|
||||
install-tests-groups :=
|
||||
|
||||
ifdef HOST_OS
|
||||
HOST_KERNEL = $(firstword $(subst -, ,$(HOST_OS)))
|
||||
|
@ -122,6 +123,14 @@ $(foreach script, $(bin-scripts), $(eval programs-list += $(script)))
|
|||
$(foreach script, $(noinst-scripts), $(eval programs-list += $(script)))
|
||||
$(foreach template, $(template-files), $(eval $(call instantiate-template,$(template))))
|
||||
$(foreach test, $(install-tests), $(eval $(call run-install-test,$(test))))
|
||||
$(foreach test, $(install-tests), $(eval installcheck: $(test).test))
|
||||
$(foreach test-group, $(install-tests-groups), \
|
||||
$(eval installcheck: $(test-group).test-group) \
|
||||
$(eval .PHONY: $(test-group).test-group) \
|
||||
$(foreach test, $($(test-group)-tests), \
|
||||
$(eval $(call run-install-test,$(test))) \
|
||||
$(eval $(test-group).test-group: $(test).test)))
|
||||
|
||||
$(foreach file, $(man-pages), $(eval $(call install-data-in, $(file), $(mandir)/man$(patsubst .%,%,$(suffix $(file))))))
|
||||
|
||||
|
||||
|
|
|
@ -2,10 +2,7 @@
|
|||
|
||||
test-deps =
|
||||
|
||||
define run-install-test
|
||||
|
||||
installcheck: $1.test
|
||||
|
||||
define run-install-test $1
|
||||
.PHONY: $1.test
|
||||
$1.test: $1 $(test-deps)
|
||||
@env BASH=$(bash) $(bash) mk/run-test.sh $1 < /dev/null
|
||||
|
|
|
@ -135,9 +135,13 @@ nix_tests = \
|
|||
flakes/show.sh \
|
||||
impure-derivations.sh \
|
||||
path-from-hash-part.sh \
|
||||
toString-path.sh \
|
||||
overlay-local-store/outer.sh \
|
||||
overlay-local-store/bad-uris.sh
|
||||
toString-path.sh
|
||||
|
||||
overlay-local-store-tests := \
|
||||
$(d)/overlay-local-store/outer.sh \
|
||||
$(d)/overlay-local-store/bad-uris.sh
|
||||
|
||||
install-tests-groups += overlay-local-store
|
||||
|
||||
ifeq ($(HAVE_LIBCPUID), 1)
|
||||
nix_tests += compute-levels.sh
|
||||
|
|
Loading…
Reference in a new issue