]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
extensions: libxt_tos: add unit test
authorPablo Neira Ayuso <pablo@netfilter.org>
Wed, 12 Sep 2012 10:42:19 +0000 (12:42 +0200)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 7 Oct 2013 14:35:48 +0000 (16:35 +0200)
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
extensions/libxt_tos.t [new file with mode: 0644]

diff --git a/extensions/libxt_tos.t b/extensions/libxt_tos.t
new file mode 100644 (file)
index 0000000..ccbe800
--- /dev/null
@@ -0,0 +1,13 @@
+:INPUT,FORWARD,OUTPUT
+-m tos --tos Minimize-Delay;-m tos --tos 0x10/0x3f;OK
+-m tos --tos Maximize-Throughput;-m tos --tos 0x08/0x3f;OK
+-m tos --tos Maximize-Reliability;-m tos --tos 0x04/0x3f;OK
+-m tos --tos Minimize-Cost;-m tos --tos 0x02/0x3f;OK
+-m tos --tos Normal-Service;-m tos --tos 0x00/0x3f;OK
+-m tos --tos 0xff;=;OK
+-m tos ! --tos 0xff;=;OK
+-m tos --tos 0x00;=;OK
+-m tos --tos 0x0f;=;OK
+-m tos --tos 0x0f/0x0f;=;OK
+-m tos --tos wrong;;FAIL
+-m tos;;FAIL