summaryrefslogtreecommitdiffstats
path: root/tests/shell/testcases/sets/0031set_timeout_size_0
diff options
context:
space:
mode:
Diffstat (limited to 'tests/shell/testcases/sets/0031set_timeout_size_0')
-rwxr-xr-xtests/shell/testcases/sets/0031set_timeout_size_014
1 files changed, 3 insertions, 11 deletions
diff --git a/tests/shell/testcases/sets/0031set_timeout_size_0 b/tests/shell/testcases/sets/0031set_timeout_size_0
index 89af58f3..3d3f919a 100755
--- a/tests/shell/testcases/sets/0031set_timeout_size_0
+++ b/tests/shell/testcases/sets/0031set_timeout_size_0
@@ -1,15 +1,7 @@
#!/bin/bash
-tmpfile=$(mktemp)
-if [ ! -w $tmpfile ] ; then
- echo "Failed to create tmp file" >&2
- exit 0
-fi
-
-trap "rm -rf $tmpfile" EXIT # cleanup if aborted
-
-echo "add table x
-add set x y { type ipv4_addr; size 128; timeout 30s; }" > $tmpfile
+RULESET="add table x
+add set x y { type ipv4_addr; size 128; timeout 30s; }"
set -e
-$NFT -f $tmpfile
+$NFT -f - <<< $RULESET