mirror of https://github.com/ARMmbed/mbed-os.git
For timer / timeout related tests deviation changed to +/- 10% - some boards can run on not precise quartz / RC oscilators
parent
3a31537cfb
commit
eec7671fa0
|
@ -49,7 +49,7 @@ class WaitusTest(DefaultTest):
|
||||||
if i > 2: # we will ignore first few measurements
|
if i > 2: # we will ignore first few measurements
|
||||||
delta = time() - start
|
delta = time() - start
|
||||||
deviation = abs(delta - 1)
|
deviation = abs(delta - 1)
|
||||||
deviation_ok = True if delta > 0 and deviation <= 0.05 else False # +/-5%
|
deviation_ok = True if delta > 0 and deviation <= 0.10 else False # +/-10%
|
||||||
test_result = test_result and deviation_ok
|
test_result = test_result and deviation_ok
|
||||||
msg = "OK" if deviation_ok else "FAIL"
|
msg = "OK" if deviation_ok else "FAIL"
|
||||||
print ". in %.2f sec (%.2f) [%s]" % (delta, deviation, msg)
|
print ". in %.2f sec (%.2f) [%s]" % (delta, deviation, msg)
|
||||||
|
|
Loading…
Reference in New Issue