Increase rate/burst allowed offset
I noticed this test became flaky once in a many runs over few months, only on upstream, regardless of neutron changes. The check which fails uses 2% offset from target value, which is small error margin, increasing to 5%. Change-Id: I3ca7b253557a199b812e50b67da4129a6ef3ab04
This commit is contained in:
parent
1bb1e4c108
commit
9c71eed490
@ -631,9 +631,10 @@ class BaseSecGroupLoggingTest(
|
||||
quick_test_target = burst_limit + rate_limit
|
||||
quick_test_logs_amount = self._hypervisors_counts[
|
||||
vm_a['hv_ssh_client'].host]['test_logs_amount']
|
||||
offset = 0.1
|
||||
self.assertIn(quick_test_logs_amount,
|
||||
range(round(0.9 * quick_test_target),
|
||||
round(1.1 * quick_test_target)),
|
||||
range(round((1 - offset) * quick_test_target),
|
||||
round((1 + offset) * quick_test_target)),
|
||||
limits_fail_msg)
|
||||
# 16) send excessive ICMP requests to VM for 60 seconds
|
||||
self.start_track_log(vm_a['hv_ssh_client'])
|
||||
@ -643,13 +644,14 @@ class BaseSecGroupLoggingTest(
|
||||
timeout=70)
|
||||
self.retrieve_tracked_log(vm_a['hv_ssh_client'])
|
||||
# 17) verify log entries amount equals to:
|
||||
# rate limit * 60 + burst limit (up to 2% offset allowed)
|
||||
# rate limit * 60 + burst limit (up to 5% offset allowed)
|
||||
long_test_target = rate_limit * 60 + burst_limit
|
||||
long_test_logs_amount = self._hypervisors_counts[
|
||||
vm_a['hv_ssh_client'].host]['test_logs_amount']
|
||||
offset = 0.05
|
||||
self.assertIn(long_test_logs_amount,
|
||||
range(round(0.98 * long_test_target),
|
||||
round(1.02 * long_test_target)),
|
||||
range(round((1 - offset) * long_test_target),
|
||||
round((1 + offset) * long_test_target)),
|
||||
limits_fail_msg)
|
||||
|
||||
# NOTE(mblue): skip multi-compute test when setup is single node
|
||||
|
Loading…
Reference in New Issue
Block a user