From: Florian Westphal Date: Fri, 9 Sep 2016 12:14:16 +0000 (+0200) Subject: tests: catch ordering issue w. ether set X-Git-Tag: v0.7~78 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=03d7eb8c260b85e77fea305736a352bbc0e94769;p=thirdparty%2Fnftables.git tests: catch ordering issue w. ether set Before previous commit, ether set (payload statement) was reversed on output: ether daddr set 00:03:2d:2b:74:ec would be shown as 'ec:74:2b:2d:03:00'. With ff:ff:ff ... such bug doesn't appear so use something where it will show up. Signed-off-by: Florian Westphal Acked-by: Pablo Neira Ayuso --- diff --git a/tests/py/bridge/ether.t b/tests/py/bridge/ether.t index 4a177ab0..5c6766eb 100644 --- a/tests/py/bridge/ether.t +++ b/tests/py/bridge/ether.t @@ -7,4 +7,4 @@ tcp dport 22 ip daddr 1.2.3.4 ether saddr 00:0f:54:0c:11:04;ok;tcp dport 22 ethe tcp dport 22 ether saddr 00:0f:54:0c:11:04 ip daddr 1.2.3.4;ok ether saddr 00:0f:54:0c:11:04 ip daddr 1.2.3.4 accept;ok -ether daddr 00:01:02:03:04:05 ether saddr set ff:ff:ff:ff:ff:ff drop;ok +ether daddr 00:01:02:03:04:05 ether saddr set ff:fe:dc:ba:98:76 drop;ok diff --git a/tests/py/bridge/ether.t.payload b/tests/py/bridge/ether.t.payload index c545d657..74956b64 100644 --- a/tests/py/bridge/ether.t.payload +++ b/tests/py/bridge/ether.t.payload @@ -42,11 +42,11 @@ bridge test-bridge input [ cmp eq reg 1 0x04030201 ] [ immediate reg 0 accept ] -# ether daddr 00:01:02:03:04:05 ether saddr set ff:ff:ff:ff:ff:ff drop +# ether daddr 00:01:02:03:04:05 ether saddr set ff:fe:dc:ba:98:76 drop bridge test-bridge input [ payload load 6b @ link header + 0 => reg 1 ] [ cmp eq reg 1 0x03020100 0x00000504 ] - [ immediate reg 1 0xffffffff 0x0000ffff ] + [ immediate reg 1 0xbadcfeff 0x00007698 ] [ payload write reg 1 => 6b @ link header + 6 csum_type 0 csum_off 0 ] [ immediate reg 0 drop ]