From b7459b0c854fc7a0d6cd86151b81035a8edf8e63 Mon Sep 17 00:00:00 2001 From: Florian Westphal Date: Fri, 17 May 2019 13:57:23 +0200 Subject: tests: shell: avoid single-value anon sets Future change is going to auto-change them to simple compare ops rather than lookup in set with only one element. Signed-off-by: Florian Westphal --- tests/shell/testcases/netns/0001nft-f_0 | 6 +++--- tests/shell/testcases/netns/0002loosecommands_0 | 6 +++--- tests/shell/testcases/netns/0003many_0 | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) (limited to 'tests/shell/testcases/netns') diff --git a/tests/shell/testcases/netns/0001nft-f_0 b/tests/shell/testcases/netns/0001nft-f_0 index 83448087..89bf5a3d 100755 --- a/tests/shell/testcases/netns/0001nft-f_0 +++ b/tests/shell/testcases/netns/0001nft-f_0 @@ -16,7 +16,7 @@ RULESET="table ip t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip saddr @s drop jump other } @@ -32,7 +32,7 @@ table ip6 t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip6 saddr @s drop jump other } @@ -48,7 +48,7 @@ table inet t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip6 saddr @s drop jump other } diff --git a/tests/shell/testcases/netns/0002loosecommands_0 b/tests/shell/testcases/netns/0002loosecommands_0 index e6278280..abef50a1 100755 --- a/tests/shell/testcases/netns/0002loosecommands_0 +++ b/tests/shell/testcases/netns/0002loosecommands_0 @@ -30,9 +30,9 @@ netns_exec $NETNS_NAME "$NFT add table ip t" netns_exec $NETNS_NAME "$NFT add chain ip t c" netns_exec $NETNS_NAME "$NFT add chain ip t other" netns_exec $NETNS_NAME "$NFT add set ip t s { type ipv4_addr; }" -netns_exec $NETNS_NAME "$NFT add element ip t s {1.1.0.0 }" +netns_exec $NETNS_NAME "$NFT add element ip t s {1.1.0.0}" netns_exec $NETNS_NAME "$NFT add rule ip t c ct state new" -netns_exec $NETNS_NAME "$NFT add rule ip t c udp dport { 12345 }" +netns_exec $NETNS_NAME "$NFT add rule ip t c udp dport 12345" netns_exec $NETNS_NAME "$NFT add rule ip t c ip saddr @s drop" netns_exec $NETNS_NAME "$NFT add rule ip t c jump other" @@ -44,7 +44,7 @@ RULESET="table ip t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip saddr @s drop jump other } diff --git a/tests/shell/testcases/netns/0003many_0 b/tests/shell/testcases/netns/0003many_0 index 61ad37bd..36b29cfb 100755 --- a/tests/shell/testcases/netns/0003many_0 +++ b/tests/shell/testcases/netns/0003many_0 @@ -19,7 +19,7 @@ RULESET="table ip t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip saddr @s drop jump other } @@ -35,7 +35,7 @@ table ip6 t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip6 saddr @s drop jump other } @@ -51,7 +51,7 @@ table inet t { chain c { ct state new - udp dport { 12345 } + udp dport 12345 ip6 saddr @s drop jump other } -- cgit v1.2.3