summaryrefslogtreecommitdiffstats
path: root/tests/py/ip6
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2018-09-11 22:14:27 +0200
committerFlorian Westphal <fw@strlen.de>2018-09-13 10:43:05 +0200
commit68e21ac5b2f5f7e60d3e1b12a3a2a05ed542f6fa (patch)
treedc8e2abfce65a3006fa2e628fb77860361546750 /tests/py/ip6
parentcbbdb960a262d8df86a2dfaa1b56c0182e97f3ed (diff)
tests/py: Fix JSON for icmp*.t
A recent change to ip/icmp.t and ip6/icmpv6.t did not update JSON equivalents accordingly, fix this. Fixes: 0f44d4f627535 ("proto: fix icmp/icmpv6 code datatype") Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'tests/py/ip6')
-rw-r--r--tests/py/ip6/icmpv6.t.json6
-rw-r--r--tests/py/ip6/icmpv6.t.json.output40
2 files changed, 43 insertions, 3 deletions
diff --git a/tests/py/ip6/icmpv6.t.json b/tests/py/ip6/icmpv6.t.json
index 73b9277a..f6cfbf17 100644
--- a/tests/py/ip6/icmpv6.t.json
+++ b/tests/py/ip6/icmpv6.t.json
@@ -519,7 +519,7 @@
}
]
-# icmpv6 code != {5, 6, 7} accept
+# icmpv6 code != {policy-fail, reject-route, 7} accept
[
{
"match": {
@@ -532,8 +532,8 @@
"op": "!=",
"right": {
"set": [
- 5,
- 6,
+ "policy-fail",
+ "reject-route",
7
]
}
diff --git a/tests/py/ip6/icmpv6.t.json.output b/tests/py/ip6/icmpv6.t.json.output
index 472b2ce7..17032a03 100644
--- a/tests/py/ip6/icmpv6.t.json.output
+++ b/tests/py/ip6/icmpv6.t.json.output
@@ -93,3 +93,43 @@
}
]
+# icmpv6 code 4
+[
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "code",
+ "protocol": "icmpv6"
+ }
+ },
+ "op": "==",
+ "right": "port-unreachable"
+ }
+ }
+]
+
+# icmpv6 code {5, 6, 7} accept
+[
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "code",
+ "protocol": "icmpv6"
+ }
+ },
+ "op": "==",
+ "right": {
+ "set": [
+ "policy-fail",
+ "reject-route",
+ 7
+ ]
+ }
+ }
+ },
+ {
+ "accept": null
+ }
+]