From e27675bc10581497aef8d6042c7fe2f80616cf38 Mon Sep 17 00:00:00 2001 From: Martine Lenders Date: Wed, 14 Apr 2021 11:11:42 +0200 Subject: [PATCH] tests/periph_rtt_min: adapt for slower RTTs --- tests/periph_rtt_min/main.c | 3 +-- tests/periph_rtt_min/tests/01-run.py | 9 +++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/periph_rtt_min/main.c b/tests/periph_rtt_min/main.c index 6c86b26e7a88..9c598621b5b8 100644 --- a/tests/periph_rtt_min/main.c +++ b/tests/periph_rtt_min/main.c @@ -68,8 +68,7 @@ int main(void) if (offset > value) { value = offset; } - printf("."); - fflush(stdout); + printf("Sample %u\n", i); samples++; } printf("\n"); diff --git a/tests/periph_rtt_min/tests/01-run.py b/tests/periph_rtt_min/tests/01-run.py index 1a9f27c490f7..dd5d003d6220 100755 --- a/tests/periph_rtt_min/tests/01-run.py +++ b/tests/periph_rtt_min/tests/01-run.py @@ -15,10 +15,11 @@ def testfunc(child): child.expect(r"Evaluate RTT_MIN_OFFSET over (\d+) samples") exp_samples = int(child.match.group(1)) - child.expect( - r'RTT_MIN_OFFSET for [a-zA-Z\-\_0-9]+ over {samples} samples: \d+' - .format(samples=exp_samples) - ) + test_end = r'RTT_MIN_OFFSET for [a-zA-Z\-\_0-9]+ over {samples} ' \ + r'samples: \d+'.format(samples=exp_samples) + test_ongoing = r'Sample \d+' + while child.expect([test_end, test_ongoing]): + pass if __name__ == "__main__":