Gave module proj auto parent cycle and removed that for assert clones.
All checks were successful
Run test asserts / Test-Asserts (push) Successful in 5s

This commit is contained in:
Willem Cazander 2024-07-18 11:18:45 +02:00
parent e9f91f1e96
commit bc70369c37
12 changed files with 82 additions and 53 deletions

View file

@ -2,9 +2,7 @@
define __mb-flow-assert-grep-binary-x
.RECIPEPREFIX := $(MB_@RECIPE)
$(1)/@$(5)-deps:: $(1)/@assert/$(5)/$(2)
$(1)/@assert/$(5)/$(2): $(1)/@build
$(1)/@assert/$(5)/$(2): $(1)/@$(5)
$(MB_@RECIPE)@echo -n "$(MB_I18N_OS_CRAYON_TAG) "
$(MB_@RECIPE)grep --colour$(MB_MAKE_EQUALS)auto -U "$(4)" $(1)/$(3)
$(MB_@RECIPE)$$(call mb-make-call,mb-os-echo-assert,$$(MB_I18N_ASSERT_SUCCESS) $(1)/@assert/$(2)/$(5))
@ -13,6 +11,7 @@ $(MB_   )$$(call mb-make-call,mb-doc-target-assert,$(1)/@assert/$
$(MB_   )$$(call mb-make-call,mb-make-target-phony,$(1)/@assert/$(5)/$(2))
$(MB_   )$$(call mb-make-call,mb-proj-grow-deps-phase,$(5),$(1)/@assert/$(5)/$(2))
$(1)/@$(5)-deps:: $(1)/@assert/$(5)/$(2)
.RECIPEPREFIX := $(MB_@RECIPEPREFIX)
endef
define mb-flow-assert-grep-binary-test
@ -30,10 +29,7 @@ $(call mb-make-call,mb-doc-function-flow,mb-flow-assert-grep-binary-package-qa,I
define __mb-flow-assert-msxpipe-grep-x
.RECIPEPREFIX := $(MB_@RECIPE)
$(1)/@$(5)-deps:: $(1)/@assert/$(5)/$(2)
$(7)/@@init-deps:: $(1)/@build
$(1)/@assert/$(5)/$(2): $(7)/@build
$(1)/@assert/$(5)/$(2): $(7)/@$(5)
$(MB_@RECIPE)$$(if $$(wildcard $(7)/$(3).out),,$$(call mb-make-call,mb-os-file-delete,$(7)/$(3).out))
$(MB_@RECIPE)$$(call mb-make-call,mb-msxpipe-safe-assert,$(7),$(3) > $(3).out,$(6))
$(MB_@RECIPE)@echo -n "$(MB_I18N_OS_CRAYON_TAG) "
@ -44,17 +40,18 @@ $(MB_   )$$(call mb-make-call,mb-doc-target-assert,$(1)/@assert/$
$(MB_   )$$(call mb-make-call,mb-make-target-phony,$(1)/@assert/$(5)/$(2))
$(MB_   )$$(call mb-make-call,mb-proj-grow-deps-phase,$(5),$(1)/@assert/$(5)/$(2))
$(1)/@$(5)-deps:: $(1)/@assert/$(5)/$(2)
.RECIPEPREFIX := $(MB_@RECIPEPREFIX)
endef
define mb-flow-assert-msxpipe-grep-test
$(MB_   )$(call mb-make-call,mb-make-check-arg5,$(0),$(1),$(2),$(3),$(4),$(5))
$(MB_   )$(eval $(call mb-make-call,mb-flow-clone-deps,$(1)$(MB_@WORK)_assert/$(notdir $(1))/test-$(3),$(1),$(2),$(6),$(7)))
$(MB_   )$(eval $(call mb-make-call,mb-flow-clone-deps-proj-setup-orphan,$(1)$(MB_@WORK)_assert/$(notdir $(1))/test-$(3),$(1),$(2),$(6),$(7)))
$(MB_   )$(eval $(call mb-make-call,__mb-flow-assert-msxpipe-grep-x,$(1),$(3),$(4),$(5),@test,$(7),$(1)$(MB_@WORK)_assert/$(notdir $(1))/test-$(3)))
endef
$(call mb-make-call,mb-doc-function-flow,mb-flow-assert-msxpipe-grep-test,Inject flow of single grep assert.,<build-dir> <deps> <test-id> <cmd-name> <grep-match> [packages] [machine])
define mb_flow-assert-msxpipe-grep-package-qa
$(MB_   )$(call mb-make-call,mb-make-check-arg5,$(0),$(1),$(2),$(3),$(4),$(5))
$(MB_   )$(eval $(call mb-make-call,mb-flow-clone-deps,$(1)$(MB_@WORK)_assert/$(notdir $(1))/package-qa-$(3),$(1),$(2),$(6),$(7)))
$(MB_   )$(eval $(call mb-make-call,mb-flow-clone-deps-proj-setup-orphan,$(1)$(MB_@WORK)_assert/$(notdir $(1))/package-qa-$(3),$(1),$(2),$(6),$(7)))
$(MB_   )$(eval $(call mb-make-call,__mb-flow-assert-msxpipe-grep-x,$(1),$(3),$(4),$(5),@package-qa,$(7),$(1)$(MB_@WORK)_assert/$(notdir $(1))/package-qa-$(3)))
endef
$(call mb-make-call,mb-doc-function-flow,mb-flow-assert-msxpipe-grep-package-qa,Inject flow of single grep assert.,<build-dir> <deps> <test-id> <cmd-name> <grep-match> [packages] [machine])