From b5cc01ef2e95ae95a24f2cf6c27e94e7dd08620e Mon Sep 17 00:00:00 2001 From: Stefan Berger Date: Fri, 9 Apr 2010 07:25:02 -0400 Subject: [PATCH] nwfilter: More XML parser test cases This patch adds a couple more nwfilter test cases for the XML parser tests. --- tests/nwfilterxml2xmlin/icmp-direction-test.xml | 15 +++++++++++++++ tests/nwfilterxml2xmlin/icmp-direction2-test.xml | 15 +++++++++++++++ tests/nwfilterxml2xmlin/icmp-direction3-test.xml | 10 ++++++++++ tests/nwfilterxml2xmlin/ipt-no-macspoof-test.xml | 14 ++++++++++++++ tests/nwfilterxml2xmlout/icmp-direction-test.xml | 12 ++++++++++++ tests/nwfilterxml2xmlout/icmp-direction2-test.xml | 12 ++++++++++++ tests/nwfilterxml2xmlout/icmp-direction3-test.xml | 9 +++++++++ tests/nwfilterxml2xmlout/ipt-no-macspoof-test.xml | 9 +++++++++ tests/nwfilterxml2xmltest.c | 4 ++++ 9 files changed, 100 insertions(+) create mode 100644 tests/nwfilterxml2xmlin/icmp-direction-test.xml create mode 100644 tests/nwfilterxml2xmlin/icmp-direction2-test.xml create mode 100644 tests/nwfilterxml2xmlin/icmp-direction3-test.xml create mode 100644 tests/nwfilterxml2xmlin/ipt-no-macspoof-test.xml create mode 100644 tests/nwfilterxml2xmlout/icmp-direction-test.xml create mode 100644 tests/nwfilterxml2xmlout/icmp-direction2-test.xml create mode 100644 tests/nwfilterxml2xmlout/icmp-direction3-test.xml create mode 100644 tests/nwfilterxml2xmlout/ipt-no-macspoof-test.xml diff --git a/tests/nwfilterxml2xmlin/icmp-direction-test.xml b/tests/nwfilterxml2xmlin/icmp-direction-test.xml new file mode 100644 index 0000000000..a692d2a4e5 --- /dev/null +++ b/tests/nwfilterxml2xmlin/icmp-direction-test.xml @@ -0,0 +1,15 @@ + + f4b3f745-d23d-2ee6-218a-d5671611229b + + + + + + + + + + + + + diff --git a/tests/nwfilterxml2xmlin/icmp-direction2-test.xml b/tests/nwfilterxml2xmlin/icmp-direction2-test.xml new file mode 100644 index 0000000000..13963487cc --- /dev/null +++ b/tests/nwfilterxml2xmlin/icmp-direction2-test.xml @@ -0,0 +1,15 @@ + + d6b1a2af-def6-2898-9f8d-4a74e3c39558 + + + + + + + + + + + + + diff --git a/tests/nwfilterxml2xmlin/icmp-direction3-test.xml b/tests/nwfilterxml2xmlin/icmp-direction3-test.xml new file mode 100644 index 0000000000..b5e3dcd862 --- /dev/null +++ b/tests/nwfilterxml2xmlin/icmp-direction3-test.xml @@ -0,0 +1,10 @@ + + d6b1a2af-def6-2898-9f8d-4a74e3c39558 + + + + + + + + diff --git a/tests/nwfilterxml2xmlin/ipt-no-macspoof-test.xml b/tests/nwfilterxml2xmlin/ipt-no-macspoof-test.xml new file mode 100644 index 0000000000..ab78bd1619 --- /dev/null +++ b/tests/nwfilterxml2xmlin/ipt-no-macspoof-test.xml @@ -0,0 +1,14 @@ + + 5c6d49af-b071-6127-b4ec-6f8ed4b55335 + + + + + + + + + + + diff --git a/tests/nwfilterxml2xmlout/icmp-direction-test.xml b/tests/nwfilterxml2xmlout/icmp-direction-test.xml new file mode 100644 index 0000000000..1022adbc5c --- /dev/null +++ b/tests/nwfilterxml2xmlout/icmp-direction-test.xml @@ -0,0 +1,12 @@ + + f4b3f745-d23d-2ee6-218a-d5671611229b + + + + + + + + + + diff --git a/tests/nwfilterxml2xmlout/icmp-direction2-test.xml b/tests/nwfilterxml2xmlout/icmp-direction2-test.xml new file mode 100644 index 0000000000..2314b2db87 --- /dev/null +++ b/tests/nwfilterxml2xmlout/icmp-direction2-test.xml @@ -0,0 +1,12 @@ + + d6b1a2af-def6-2898-9f8d-4a74e3c39558 + + + + + + + + + + diff --git a/tests/nwfilterxml2xmlout/icmp-direction3-test.xml b/tests/nwfilterxml2xmlout/icmp-direction3-test.xml new file mode 100644 index 0000000000..31daef3a5c --- /dev/null +++ b/tests/nwfilterxml2xmlout/icmp-direction3-test.xml @@ -0,0 +1,9 @@ + + d6b1a2af-def6-2898-9f8d-4a74e3c39558 + + + + + + + diff --git a/tests/nwfilterxml2xmlout/ipt-no-macspoof-test.xml b/tests/nwfilterxml2xmlout/ipt-no-macspoof-test.xml new file mode 100644 index 0000000000..218ce4da4a --- /dev/null +++ b/tests/nwfilterxml2xmlout/ipt-no-macspoof-test.xml @@ -0,0 +1,9 @@ + + 5c6d49af-b071-6127-b4ec-6f8ed4b55335 + + + + + + + diff --git a/tests/nwfilterxml2xmltest.c b/tests/nwfilterxml2xmltest.c index 8a8c15a575..4dcda26315 100644 --- a/tests/nwfilterxml2xmltest.c +++ b/tests/nwfilterxml2xmltest.c @@ -114,6 +114,10 @@ mymain(int argc, char **argv) DO_TEST("ref-test"); DO_TEST("ref-rule-test"); + DO_TEST("ipt-no-macspoof-test"); + DO_TEST("icmp-direction-test"); + DO_TEST("icmp-direction2-test"); + DO_TEST("icmp-direction3-test"); return (ret==0 ? EXIT_SUCCESS : EXIT_FAILURE); }