summaryrefslogtreecommitdiffstats
path: root/tests/shell/testcases/sets/0002named_interval_automerging_0
blob: 688986387d177400cc265a961e59f41692e12d67 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash

# This testscase checks the automerging of adjacent intervals

set -e

$NFT add table t
$NFT add set t s { type ipv4_addr \; flags interval \; }
$NFT add element t s { 192.168.0.0/24, 192.168.1.0/24 }
$NFT list ruleset | grep "192.168.0.0/23" >/dev/null || exit 0
echo "E: automerging of adjacent intervals happened unexpectedly." >&2
exit 1