summaryrefslogtreecommitdiffstats
path: root/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py
diff options
context:
space:
mode:
authorLuc Provoost <luc.provoost@gmail.com>2022-09-14 15:13:32 +0000
committerLuc Provoost <luc.provoost@gmail.com>2022-09-14 15:26:07 +0000
commite7dbec331e68ca083ba079a66c1b93dd311248d6 (patch)
tree3d29a08f64ecf52ea48c1f5077d38100fb7edd3f /VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py
parentc7b632551d5e3c491c631bc4be2a8f881635e626 (diff)
Change search success criterium
When running a step in the binary search, we can now change the behaviour by adding a new parameter in the [test] section of the test file: generator_threshold. The default value for this parameter is set to inf, which results in the same behaviour as before this change was implemented. The relative difference between what the cores can generate and what is actually sent into the generator's interface must be lower than the generator_threshold, for the test to be successful. Signed-off-by: Luc Provoost <luc.provoost@gmail.com> Change-Id: Id3e787b3571bdb9f241763fceaffccb9ea81a264
Diffstat (limited to 'VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py')
-rw-r--r--VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py
index 500be5b4..ea42fc9a 100644
--- a/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py
+++ b/VNFs/DPPD-PROX/helper-scripts/rapid/rapid_flowsizetest.py
@@ -226,7 +226,14 @@ class FlowSizeTest(RapidTest):
# the drop rate is below a treshold, either we want that no
# packet has been lost during the test.
# This can be specified by putting 0 in the .test file
- elif ((iteration_data['drop_rate'] < self.test['drop_rate_threshold']) or (iteration_data['abs_dropped']==self.test['drop_rate_threshold']==0)) and (iteration_data['lat_avg']< self.test['lat_avg_threshold']) and (iteration_data['lat_perc']< self.test['lat_perc_threshold']) and (iteration_data['lat_max'] < self.test['lat_max_threshold'] and iteration_data['mis_ordered'] <= self.test['mis_ordered_threshold']):
+ elif ((self.get_pps(speed,size) - iteration_data['pps_tx']) / self.get_pps(speed,size)) \
+ < self.test['generator_threshold'] and \
+ ((iteration_data['drop_rate'] < self.test['drop_rate_threshold']) or \
+ (iteration_data['abs_dropped']==self.test['drop_rate_threshold']==0)) and \
+ (iteration_data['lat_avg']< self.test['lat_avg_threshold']) and \
+ (iteration_data['lat_perc']< self.test['lat_perc_threshold']) and \
+ (iteration_data['lat_max'] < self.test['lat_max_threshold'] and \
+ iteration_data['mis_ordered'] <= self.test['mis_ordered_threshold']):
end_data = copy.deepcopy(iteration_data)
end_prefix = copy.deepcopy(iteration_prefix)
success = True