diff options
| author | Phil Sutter <phil@nwl.cc> | 2025-10-16 14:31:46 +0200 |
|---|---|---|
| committer | Phil Sutter <phil@nwl.cc> | 2026-01-27 23:01:54 +0100 |
| commit | 0f566ac1c1dbd9f2e7d006ca01211aae791f09a8 (patch) | |
| tree | a672d67eefb7ca5b51550721c9d440bd1845a887 /tests/py/any/meta.t.payload.bridge | |
| parent | db82466117b8bfc93923eec49114d47200f7f913 (diff) | |
tests: py: Update payload records
This is the bulk change of py test suite payload records with improved
data reg printing in libnftnl using data (component) size and byteorder
collected in nftables.
Aside from printing values in the right byte order and padded with
zeroes to match their actual size, this patch also exposes the improved
set element dump format:
* No '[end]' marker, 'element' clearly separates elements
* No semi-colon for non-map elements
* 'flags' value printed only if non-zero and prefixed by 'flags' to
distinguish from element data
Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'tests/py/any/meta.t.payload.bridge')
| -rw-r--r-- | tests/py/any/meta.t.payload.bridge | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/py/any/meta.t.payload.bridge b/tests/py/any/meta.t.payload.bridge index 5997ccc7..b4e7ba37 100644 --- a/tests/py/any/meta.t.payload.bridge +++ b/tests/py/any/meta.t.payload.bridge @@ -1,20 +1,20 @@ # meta mark set vlan id map { 1 : 0x00000001, 4095 : 0x00004095 } __map%d test-bridge b size 2 __map%d test-bridge 0 - element 00000100 : 00000001 0 [end] element 0000ff0f : 00004095 0 [end] + element 0001 : 00000001 element 0fff : 00004095 bridge test-bridge input [ payload load 2b @ link header + 12 => reg 1 ] - [ cmp eq reg 1 0x00000081 ] + [ cmp eq reg 1 0x8100 ] [ payload load 2b @ link header + 14 => reg 1 ] - [ bitwise reg 1 = ( reg 1 & 0x0000ff0f ) ^ 0x00000000 ] + [ bitwise reg 1 = ( reg 1 & 0x0fff ) ^ 0x0000 ] [ lookup reg 1 set __map%d dreg 1 ] [ meta set mark with reg 1 ] # meta mark set vlan id map @map1 bridge test-bridge input [ payload load 2b @ link header + 12 => reg 1 ] - [ cmp eq reg 1 0x00000081 ] + [ cmp eq reg 1 0x8100 ] [ payload load 2b @ link header + 14 => reg 1 ] - [ bitwise reg 1 = ( reg 1 & 0x0000ff0f ) ^ 0x00000000 ] + [ bitwise reg 1 = ( reg 1 & 0x0fff ) ^ 0x0000 ] [ lookup reg 1 set map1 dreg 1 ] [ meta set mark with reg 1 ] |
