Skip to content

Commit

Permalink
tc-testing: added tests with cookie for conntrack TC action
Browse files Browse the repository at this point in the history
Signed-off-by: Roman Mashak <mrv@mojatatu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Roman Mashak authored and David S. Miller committed Nov 1, 2019
1 parent 23c161e commit c23fcbb
Showing 1 changed file with 72 additions and 0 deletions.
72 changes: 72 additions & 0 deletions tools/testing/selftests/tc-testing/tc-tests/actions/ct.json
Original file line number Diff line number Diff line change
@@ -23,6 +23,30 @@
"$TC actions flush action ct"
]
},
{
"id": "e38c",
"name": "Add simple ct action with cookie",
"category": [
"actions",
"ct"
],
"setup": [
[
"$TC actions flush action ct",
0,
1,
255
]
],
"cmdUnderTest": "$TC actions add action ct index 42 cookie deadbeef",
"expExitCode": "0",
"verifyCmd": "$TC actions list action ct",
"matchPattern": "action order [0-9]*: ct zone 0 pipe.*index 42 ref.*cookie deadbeef",
"matchCount": "1",
"teardown": [
"$TC actions flush action ct"
]
},
{
"id": "9f20",
"name": "Add ct clear action",
@@ -47,6 +71,30 @@
"$TC actions flush action ct"
]
},
{
"id": "0bc1",
"name": "Add ct clear action with cookie of max length",
"category": [
"actions",
"ct"
],
"setup": [
[
"$TC actions flush action ct",
0,
1,
255
]
],
"cmdUnderTest": "$TC actions add action ct clear index 42 cookie aa11bb22cc33dd44ee55ff66aa11b1b2",
"expExitCode": "0",
"verifyCmd": "$TC actions list action ct",
"matchPattern": "action order [0-9]*: ct clear pipe.*index 42 ref.*cookie aa11bb22cc33dd44ee55ff66aa11b1b2",
"matchCount": "1",
"teardown": [
"$TC actions flush action ct"
]
},
{
"id": "5bea",
"name": "Try ct with zone",
@@ -311,6 +359,30 @@
"$TC actions flush action ct"
]
},
{
"id": "2faa",
"name": "Try ct with mark + mask and cookie",
"category": [
"actions",
"ct"
],
"setup": [
[
"$TC actions flush action ct",
0,
1,
255
]
],
"cmdUnderTest": "$TC actions add action ct mark 0x42/0xf0 index 42 cookie aa11bb22cc33dd44ee55ff66aa11b1b2",
"expExitCode": "0",
"verifyCmd": "$TC actions list action ct",
"matchPattern": "action order [0-9]*: ct mark 66/0xf0 zone 0 pipe.*index 42 ref.*cookie aa11bb22cc33dd44ee55ff66aa11b1b2",
"matchCount": "1",
"teardown": [
"$TC actions flush action ct"
]
},
{
"id": "3991",
"name": "Add simple ct action with no_percpu flag",

0 comments on commit c23fcbb

Please sign in to comment.