diff --git a/tests/bench_runtime_coreapis/tests/01-run.py b/tests/bench_runtime_coreapis/tests/01-run.py index 9f78f46d1c..e2c56dc56e 100755 --- a/tests/bench_runtime_coreapis/tests/01-run.py +++ b/tests/bench_runtime_coreapis/tests/01-run.py @@ -12,10 +12,21 @@ from testrunner import run # The default timeout is not enough for this test on some of the slower boards TIMEOUT = 30 +BENCHMARK_REGEXP = r"\s+{func}:\s+\d+us\s+---\s+\d*\.*\d+us per call\s+---\s+\d+ calls per sec" def testfunc(child): - child.expect_exact('[SUCCESS]', timeout=TIMEOUT) + child.expect_exact('Runtime of Selected Core API functions') + child.expect(BENCHMARK_REGEXP.format(func="nop loop")) + child.expect(BENCHMARK_REGEXP.format(func=r"mutex_init\(\)")) + child.expect(BENCHMARK_REGEXP.format(func="mutex lock/unlock"), timeout=TIMEOUT) + child.expect(BENCHMARK_REGEXP.format(func=r"thread_flags_set\(\)")) + child.expect(BENCHMARK_REGEXP.format(func="thread flags set/wait any"), timeout=TIMEOUT) + child.expect(BENCHMARK_REGEXP.format(func="thread flags set/wait all"), timeout=TIMEOUT) + child.expect(BENCHMARK_REGEXP.format(func="thread flags set/wait one"), timeout=TIMEOUT) + child.expect(BENCHMARK_REGEXP.format(func=r"msg_try_receive\(\)")) + child.expect(BENCHMARK_REGEXP.format(func=r"msg_avail\(\)")) + child.expect_exact('[SUCCESS]') if __name__ == "__main__":