Previously, the crypto latency test suite would fail if a measurement
was above the baseline and still within the given delta tolerance. The
expected behavior is that it should fail if it is not within the delta
tolerance. This commit resolves this issue.
Bugzilla ID: 2103
Fixes: 2ca02cd2643c ("dts: refactor cryptodev latency test suite")
Signed-off-by: Andrew Bailey <[email protected]>
---
dts/tests/TestSuite_cryptodev_latency.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dts/tests/TestSuite_cryptodev_latency.py
b/dts/tests/TestSuite_cryptodev_latency.py
index d4693b3d4c..8349a34b96 100644
--- a/dts/tests/TestSuite_cryptodev_latency.py
+++ b/dts/tests/TestSuite_cryptodev_latency.py
@@ -248,10 +248,10 @@ def _create_summary(
# result did not meet the matching parameter, check if within
delta.
if getattr(result, "avg_cycles") > expected_cycles:
- if self.delta_tolerance > measured_delta_cycles:
+ if self.delta_tolerance < measured_delta_cycles:
test_result = False
if getattr(result, "avg_time_us") > expected_time:
- if self.delta_tolerance > measured_delta_time:
+ if self.delta_tolerance < measured_delta_time:
test_result = False
result_list.append(
--
2.56.0