]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: tests: add nwfilter specific tests
authorPavel Hrdina <phrdina@redhat.com>
Tue, 2 Jun 2020 16:42:07 +0000 (18:42 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:06 +0000 (09:27 +0200)
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
tests/Makefile.am
tests/meson.build

index 5809f7d20f6d097b5e6bc1f08b5bb228028f08a2..e61a95754556e818643dae600071846a9ae81d19 100644 (file)
@@ -77,11 +77,6 @@ if WITH_STORAGE_SHEEPDOG
 test_programs += storagebackendsheepdogtest
 endif WITH_STORAGE_SHEEPDOG
 
-if WITH_NWFILTER
-test_programs += nwfilterebiptablestest
-test_programs += nwfilterxml2firewalltest
-endif WITH_NWFILTER
-
 if WITH_STORAGE
 test_programs += storagevolxml2argvtest
 test_programs += storagepoolxml2argvtest
@@ -330,19 +325,6 @@ storagebackendsheepdogtest_LDADD = \
        $(LDADDS)
 endif WITH_STORAGE_SHEEPDOG
 
-if WITH_NWFILTER
-nwfilterebiptablestest_SOURCES = \
-       nwfilterebiptablestest.c \
-       testutils.c testutils.h
-nwfilterebiptablestest_LDADD = ../src/libvirt_driver_nwfilter_impl.la $(LDADDS)
-
-nwfilterxml2firewalltest_SOURCES = \
-       nwfilterxml2firewalltest.c \
-       testutils.c testutils.h
-nwfilterxml2firewalltest_LDADD = \
-       ../src/libvirt_driver_nwfilter_impl.la $(LDADDS)
-endif WITH_NWFILTER
-
 if WITH_STORAGE
 virstorageutiltest_SOURCES = \
        virstorageutiltest.c \
index b8cf6911f67ddb45976da3e8966595cd20302ca8..a287ce064279fe37b2b504516e1d2e2ddfe1c095 100644 (file)
@@ -427,6 +427,13 @@ if conf.has('WITH_NSS')
   ]
 endif
 
+if conf.has('WITH_NWFILTER')
+  tests += [
+    { 'name': 'nwfilterebiptablestest', 'link_with': [ nwfilter_driver_impl ] },
+    { 'name': 'nwfilterxml2firewalltest', 'link_with': [ nwfilter_driver_impl ] },
+  ]
+endif
+
 foreach data : tests
   test_sources = '@0@.c'.format(data['name'])
   test_bin = executable(