summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/test_chains.py11
1 files changed, 9 insertions, 2 deletions
diff --git a/test/test_chains.py b/test/test_chains.py
index 17c5b94..ebc606e 100644
--- a/test/test_chains.py
+++ b/test/test_chains.py
@@ -356,7 +356,11 @@ CHAIN_STATS = [{0: {'packets': [2000054, 1999996, 1999996]}},
'total': {'packets': [30000004, 30000004, 30000004, 30000004, 30000004, 30000004]}},
{0: {'packets': [15000002, '', 14000002, 14000002, '', 13000002]},
1: {'packets': [15000002, '', 15000002, 15000002, '', 15000002]},
- 'total': {'packets': [30000004, 29000004, 29000004, 29000004, 29000004, 28000004]}}]
+ 'total': {'packets': [30000004, 29000004, 29000004, 29000004, 29000004, 28000004]}},
+ # example with non-available rx count in last position
+ {0: {'packets': [2000054, 1999996, None]},
+ 1: {'packets': [2000054, 2000054, None]},
+ 'total': {'packets': [4000108, 4000050, 4000050]}}]
XP_CHAIN_STATS = [{0: {'packets': [2000054, '-58 (-0.0029%)', 1999996]}},
{0: {'packets': [2000054, '-58 (-0.0029%)', 1999996]},
1: {'packets': [2000054, '=>', 2000054]},
@@ -371,7 +375,10 @@ XP_CHAIN_STATS = [{0: {'packets': [2000054, '-58 (-0.0029%)', 1999996]}},
'-1,000,000 (-7.1429%)']},
1: {'packets': [15000002, '', '=>', '=>', '', 15000002]},
'total': {'packets': [30000004, '-1,000,000 (-3.3333%)', '=>', '=>', '=>',
- '-1,000,000 (-3.4483%)']}}]
+ '-1,000,000 (-3.4483%)']}},
+ {0: {'packets': [2000054, '-58 (-0.0029%)', 'n/a']},
+ 1: {'packets': [2000054, '=>', 'n/a']},
+ 'total': {'packets': [4000108, '-58 (-0.0014%)', 4000050]}}]
def test_summarizer():