]> git.ipfire.org Git - thirdparty/iptables.git/commitdiff
tests: libipt_icmp.t: Enable tests with numeric output
authorPhil Sutter <phil@nwl.cc>
Tue, 1 Aug 2023 21:42:24 +0000 (23:42 +0200)
committerPhil Sutter <phil@nwl.cc>
Fri, 4 Aug 2023 13:10:49 +0000 (15:10 +0200)
Unrelated to the question whether numeric (save) output is desired or
not, enable the tests and expect the known format.

Using --list without --numeric prints the names, BTW.

Fixes: 49d5b7277c7f2 ("extensions: libipt_icmp: add unit test")
Signed-off-by: Phil Sutter <phil@nwl.cc>
extensions/libipt_icmp.t

index ce4a33f9633b5bb13ad7bb0a101b8473e96fc6f2..4ea936217c09a69841f0227c708cf651096857e7 100644 (file)
@@ -1,11 +1,8 @@
 :INPUT,FORWARD,OUTPUT
 -p icmp -m icmp --icmp-type any;=;OK
-# output uses the number, better use the name?
-# ERROR: cannot find: iptables -I INPUT -p icmp -m icmp --icmp-type echo-reply
-# -p icmp -m icmp --icmp-type echo-reply;=;OK
-# output uses the number, better use the name?
-# ERROR: annot find: iptables -I INPUT -p icmp -m icmp --icmp-type destination-unreachable
-# -p icmp -m icmp --icmp-type destination-unreachable;=;OK
+# XXX: output uses the number, better use the name?
+-p icmp -m icmp --icmp-type echo-reply;-p icmp -m icmp --icmp-type 0;OK
+-p icmp -m icmp --icmp-type destination-unreachable;-p icmp -m icmp --icmp-type 3;OK
 # it does not acccept name/name, should we accept this?
 # ERROR: cannot load: iptables -A INPUT -p icmp -m icmp --icmp-type destination-unreachable/network-unreachable
 # -p icmp -m icmp --icmp-type destination-unreachable/network-unreachable;=;OK