From: Jozef Urbanovsky <jurbanov(a)redhat.com>
int conversion of result["confidence"] was truncating everything after
decimal point, therefore division was incorrect for numbers with
non-zero decimal part.
Signed-off-by: Jozef Urbanovsky <jurbanov(a)redhat.com>
---
test_modules/Netperf.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/test_modules/Netperf.py b/test_modules/Netperf.py
index 8e66215..5a6d55b 100644
--- a/test_modules/Netperf.py
+++ b/test_modules/Netperf.py
@@ -519,7 +519,7 @@ class Netperf(TestGeneric):
rate_deviation = 2*res_data["std_deviation"]
elif len(rates) == 1 and self._confidence is not None:
result = results[0]
- rate_deviation = rate * (int(result["confidence"][1]) / 100)
+ rate_deviation = rate * (float(result["confidence"][1]) / 100)
else:
rate_deviation = 0.0
--
2.20.1