]> git.ipfire.org Git - thirdparty/nftables.git/commitdiff
tests: py: remove redundant payload expressions
authorJeremy Sowden <jeremy@azazel.net>
Sat, 15 Jan 2022 18:27:08 +0000 (18:27 +0000)
committerFlorian Westphal <fw@strlen.de>
Sat, 15 Jan 2022 19:17:42 +0000 (20:17 +0100)
Now that we keep track of more payload dependencies, more redundant
payloads are eliminated.  Remove these from the Python test-cases.

Signed-off-by: Jeremy Sowden <jeremy@azazel.net>
Signed-off-by: Florian Westphal <fw@strlen.de>
tests/py/inet/icmpX.t
tests/py/inet/icmpX.t.json.output
tests/py/inet/sets.t.json

index 97ff96d0cf0e68fe0b3639e532c667c06d470809..9430b3d3d579ff390ff67aa9a1ccdef9afdc4ebf 100644 (file)
@@ -7,4 +7,4 @@ icmp type echo-request;ok
 ip6 nexthdr icmpv6 icmpv6 type echo-request;ok;ip6 nexthdr 58 icmpv6 type echo-request
 icmpv6 type echo-request;ok
 # must not remove 'ip protocol' dependency, this explicitly matches icmpv6-in-ipv4.
-ip protocol ipv6-icmp meta l4proto ipv6-icmp icmpv6 type 1;ok;ip protocol 58 meta l4proto 58 icmpv6 type destination-unreachable
+ip protocol ipv6-icmp meta l4proto ipv6-icmp icmpv6 type 1;ok;ip protocol 58 icmpv6 type destination-unreachable
index 9b0bf9f75ed5a709cbca57244c434eb39a7c143f..7765cd908e24ec3b391d1f24d6199e290b101e1b 100644 (file)
             "right": 58
         }
     },
-    {
-        "match": {
-            "left": {
-                "meta": { "key": "l4proto" }
-            },
-           "op": "==",
-            "right": 58
-        }
-    },
     {
         "match": {
             "left": {
index ef0cedca81595e0aa0ac063ba2d88af25cb85dce..b44ffc20d70d6ca4a09c08e69bcd8835cf582f60 100644 (file)
 
 # ip daddr . tcp dport { 10.0.0.0/8 . 10-23, 192.168.1.1-192.168.3.8 . 80-443 } accept
 [
-    {
-        "match": {
-            "left": {
-                "meta": {
-                    "key": "nfproto"
-                }
-            },
-            "op": "==",
-            "right": "ipv4"
-        }
-    },
     {
         "match": {
             "left": {