Commit 7061f9c8 authored by Dridi Boukelmoune's avatar Dridi Boukelmoune

build: Move the VMODs tests out of the boilerplate

We can't have more than one test suite if we put all VMODs in the same
directory.
parent 26d73696
......@@ -88,19 +88,6 @@ CLEANFILES = $(builddir)/PFX.c $(builddir)/PFX.h \\
\t$(builddir)/vmod_XXX.man.rst
'''
AMBOILERPLATE_CHECK = '''
TESTS = \\
\tVTC
EXTRA_DIST += $(TESTS)
vtc-refresh-tests:
\t@PYTHON@ $(vmodtool) $(vmodtoolargs) $(srcdir)/VCC
\t@cd $(top_builddir) && ./config.status --file=$(subdir)/Makefile
include $(top_srcdir)/vtc.am
'''
PRIVS = {
'PRIV_CALL': "struct vmod_priv *",
'PRIV_VCL': "struct vmod_priv *",
......@@ -992,11 +979,6 @@ class vcc(object):
fo.write(AMBOILERPLATE.replace("XXX", self.modname)
.replace("VCC", vcc)
.replace("PFX", self.pfx))
tests = glob.glob("tests/*.vtc")
if len(tests) > 0:
tests.sort()
fo.write(AMBOILERPLATE_CHECK.replace("VCC", vcc).
replace("VTC", " \\\n\t".join(tests)))
fo.close()
def mkdefs(self, fo):
......
......@@ -3,3 +3,29 @@ libvmod_cookie_la_SOURCES = \
# Use vmodtool.py generated automake boilerplate
include $(srcdir)/automake_boilerplate_cookie.am
TESTS = \
tests/cookie_b00000.vtc \
tests/cookie_b00001.vtc \
tests/cookie_b00002.vtc \
tests/cookie_b00003.vtc \
tests/cookie_b00004.vtc \
tests/cookie_b00005.vtc \
tests/cookie_b00006.vtc \
tests/cookie_b00007.vtc \
tests/cookie_b00008.vtc \
tests/cookie_b00009.vtc \
tests/cookie_b00010.vtc \
tests/cookie_b00011.vtc \
tests/cookie_b00012.vtc \
tests/cookie_b00013.vtc \
tests/cookie_r00028.vtc \
tests/cookie_v00000.vtc
EXTRA_DIST += $(TESTS)
vtc-refresh-tests:
@PYTHON@ $(vmodtool) $(vmodtoolargs) $(srcdir)/vmod_cookie.vcc
@cd $(top_builddir) && ./config.status --file=$(subdir)/Makefile
include $(top_srcdir)/vtc.am
......@@ -35,29 +35,3 @@ EXTRA_DIST = $(srcdir)/vmod_cookie.vcc automake_boilerplate_cookie.am
CLEANFILES = $(builddir)/vcc_cookie_if.c $(builddir)/vcc_cookie_if.h \
$(builddir)/vmod_cookie.rst \
$(builddir)/vmod_cookie.man.rst
TESTS = \
tests/cookie_b00000.vtc \
tests/cookie_b00001.vtc \
tests/cookie_b00002.vtc \
tests/cookie_b00003.vtc \
tests/cookie_b00004.vtc \
tests/cookie_b00005.vtc \
tests/cookie_b00006.vtc \
tests/cookie_b00007.vtc \
tests/cookie_b00008.vtc \
tests/cookie_b00009.vtc \
tests/cookie_b00010.vtc \
tests/cookie_b00011.vtc \
tests/cookie_b00012.vtc \
tests/cookie_b00013.vtc \
tests/cookie_r00028.vtc \
tests/cookie_v00000.vtc
EXTRA_DIST += $(TESTS)
vtc-refresh-tests:
@PYTHON@ $(vmodtool) $(vmodtoolargs) $(srcdir)/vmod_cookie.vcc
@cd $(top_builddir) && ./config.status --file=$(subdir)/Makefile
include $(top_srcdir)/vtc.am
......@@ -8,3 +8,14 @@ libvmod_std_la_SOURCES = \
# Use vmodtool.py generated automake boilerplate
include $(srcdir)/automake_boilerplate_std.am
TESTS = \
tests/std_b00001.vtc
EXTRA_DIST += $(TESTS)
vtc-refresh-tests:
@PYTHON@ $(vmodtool) $(vmodtoolargs) $(srcdir)/vmod_std.vcc
@cd $(top_builddir) && ./config.status --file=$(subdir)/Makefile
include $(top_srcdir)/vtc.am
......@@ -35,14 +35,3 @@ EXTRA_DIST = $(srcdir)/vmod_std.vcc automake_boilerplate_std.am
CLEANFILES = $(builddir)/vcc_std_if.c $(builddir)/vcc_std_if.h \
$(builddir)/vmod_std.rst \
$(builddir)/vmod_std.man.rst
TESTS = \
tests/std_b00001.vtc
EXTRA_DIST += $(TESTS)
vtc-refresh-tests:
@PYTHON@ $(vmodtool) $(vmodtoolargs) $(srcdir)/vmod_std.vcc
@cd $(top_builddir) && ./config.status --file=$(subdir)/Makefile
include $(top_srcdir)/vtc.am
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment