]> git.ipfire.org Git - people/jschlag/network.git/commitdiff
nitsi: Create "nitsi" Makefile target
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 4 Jun 2018 15:38:26 +0000 (16:38 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 15 Jun 2018 11:25:36 +0000 (12:25 +0100)
Calling "make nitsi" will run all nitsi tests

Reviewed-by: Jonatan Schlag <jonatan.schlag@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
configure.ac

index 7a755cc264a107dbe11a32609361981088a5a9fb..c02376462cf49dd5f39eb949a473945f262eb6e2 100644 (file)
@@ -89,6 +89,10 @@ INSTALL_EXEC_HOOKS += \
 
 # ------------------------------------------------------------------------------
 
+AM_V_NITSI   = $(AM_V_NITSI_$(V))
+AM_V_NITSI_  = $(AM_V_NITSI_$(AM_DEFAULT_VERBOSITY))
+AM_V_NITSI_0 = @echo "  NITSI   " $@;
+
 AM_V_XSLT   = $(AM_V_XSLT_$(V))
 AM_V_XSLT_  = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
 AM_V_XSLT_0 = @echo "  XSLT    " $@;
@@ -543,3 +547,21 @@ TESTS = \
        test/functions/ip/ip_prefix_is_valid \
        test/functions/ip/ip_protocol_is_supported \
        test/functions/ip/ip_split_prefix
+
+# - NITSI tests ----------------------------------------------------------------
+
+NITSI_TESTS = \
+       test/nitsi/test/hello-world
+
+EXTRA_DIST += \
+       test/nitsi/test/hello-world/recipe \
+       test/nitsi/test/hello-world/settings
+
+NITSI_ENVIRONMENT =
+
+.PHONY: $(NITSI_TESTS)
+$(NITSI_TESTS):
+       $(AM_V_NITSI) $(NITSI_ENVIRONMENT) $(NITSI) --log-level error -d $@
+
+.PHONY: nitsi
+nitsi: $(NITSI_TESTS)
index 7cb5ef1110fa393606d66f9b215fd61f2940b474..515941451aba852b3937975502ebe4103f214c78 100644 (file)
@@ -50,6 +50,7 @@ AC_PROG_LN_S
 AC_PROG_MKDIR_P
 AC_PROG_SED
 
+AC_PATH_PROG([NITSI], [nitsi])
 AC_PATH_PROG([XSLTPROC], [xsltproc])
 
 # pkg-config