summaryrefslogtreecommitdiffstats
path: root/tests/shell/testcases/sets/0024named_objects_0
diff options
context:
space:
mode:
Diffstat (limited to 'tests/shell/testcases/sets/0024named_objects_0')
-rwxr-xr-xtests/shell/testcases/sets/0024named_objects_048
1 files changed, 0 insertions, 48 deletions
diff --git a/tests/shell/testcases/sets/0024named_objects_0 b/tests/shell/testcases/sets/0024named_objects_0
deleted file mode 100755
index 21200c3c..00000000
--- a/tests/shell/testcases/sets/0024named_objects_0
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/bin/bash
-
-# This is the testscase:
-# * creating valid named objects
-# * referencing them from a valid rule
-
-RULESET="
-table inet x {
- counter user123 {
- packets 12 bytes 1433
- }
- counter user321 {
- packets 12 bytes 1433
- }
- quota user123 {
- over 2000 bytes
- }
- quota user124 {
- over 2000 bytes
- }
- set y {
- type ipv4_addr
- }
- map test {
- type ipv4_addr : quota
- elements = { 192.168.2.2 : "user124", 192.168.2.3 : "user124"}
- }
- chain y {
- type filter hook input priority 0; policy accept;
- counter name ip saddr map { 192.168.2.2 : "user123", 1.1.1.1 : "user123", 2.2.2.2 : "user123"}
- quota name ip saddr map @test drop
- }
-}"
-
-set -e
-$NFT -f - <<< "$RULESET"
-
-EXPECTED="table inet x {
- counter user321 {
- packets 12 bytes 1433
- }
-}"
-
-GET="$($NFT reset counter inet x user321)"
-if [ "$EXPECTED" != "$GET" ] ; then
- $DIFF -u <(echo "$EXPECTED") <(echo "$GET")
- exit 1
-fi