From 69227b8be7036391ade6751d9abc738714583332 Mon Sep 17 00:00:00 2001 From: Delyan Angelov Date: Wed, 23 Jun 2021 14:14:53 +0300 Subject: [PATCH] tests: bump up sleep times in break_in_lock_test.v, so that its results are stabler --- vlib/v/tests/break_in_lock_test.v | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/vlib/v/tests/break_in_lock_test.v b/vlib/v/tests/break_in_lock_test.v index d40079c2c9..d2048deb52 100644 --- a/vlib/v/tests/break_in_lock_test.v +++ b/vlib/v/tests/break_in_lock_test.v @@ -6,8 +6,8 @@ mut: } const ( - run_time = time.millisecond * 200 // must be big enough to ensure threads have started - sleep_time = time.millisecond * 250 // some tolerance added + run_time = time.millisecond * 500 // must be big enough to ensure threads have started + sleep_time = time.millisecond * 2000 // some tolerance added ) fn test_return_lock() { @@ -18,6 +18,7 @@ fn test_return_lock() { for { reader(shared s) if time.now() - start > run_time { + eprintln('> ${@FN} exited') exit(0) } } @@ -32,6 +33,7 @@ fn printer(shared s AA, start time.Time) { assert s.b in ['0', '1', '2', '3', '4', '5'] } if time.now() - start > run_time { + eprintln('> ${@FN} exited') exit(0) } }