summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2018-04-13 16:52:31 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2018-04-14 13:53:02 +0200
commitf481851b0dbaeb76ecc5c355e4a9cc8c5da71956 (patch)
treef25687484445c27f60085a03ab5356bf9f3675f1 /tests
parente20513ffe57c532e397ed5015ce58266870da5a4 (diff)
tests/py: Fix differences printing for rules with sets
If a rule contained a set, it would always print the tested rule as differing from the output instead of any given output (if defined). Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests')
-rwxr-xr-xtests/py/nft-test.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/py/nft-test.py b/tests/py/nft-test.py
index d5cb25b3..d4b22817 100755
--- a/tests/py/nft-test.py
+++ b/tests/py/nft-test.py
@@ -737,8 +737,8 @@ def rule_add(rule, filename, lineno, force_all_family_option, filename_path):
if set_check_element(teoric_exit.rstrip(), rule_output.rstrip()) != 0:
warning += 1
print_differences_warning(filename, lineno,
- rule[0], rule_output,
- cmd)
+ teoric_exit.rstrip(),
+ rule_output, cmd)
if not force_all_family_option:
return [ret, warning, error, unit_tests]
else: