aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/test/unicode_util_SUITE.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2017-10-13 14:35:07 +0200
committerDan Gudmundsson <[email protected]>2017-11-29 13:17:11 +0100
commit34df9b51b0237172c41e81fd5ae5597cba534473 (patch)
tree78fa3a510abcd30e73277fe587e34f2b79730d42 /lib/stdlib/test/unicode_util_SUITE.erl
parent8350886687735b3552f41780563eedac7e6650e7 (diff)
downloadotp-34df9b51b0237172c41e81fd5ae5597cba534473.tar.gz
otp-34df9b51b0237172c41e81fd5ae5597cba534473.tar.bz2
otp-34df9b51b0237172c41e81fd5ae5597cba534473.zip
Avoid falling measurements testcases on slow machines
Diffstat (limited to 'lib/stdlib/test/unicode_util_SUITE.erl')
-rw-r--r--lib/stdlib/test/unicode_util_SUITE.erl15
1 files changed, 13 insertions, 2 deletions
diff --git a/lib/stdlib/test/unicode_util_SUITE.erl b/lib/stdlib/test/unicode_util_SUITE.erl
index f23e6b8b9a..a89627eba5 100644
--- a/lib/stdlib/test/unicode_util_SUITE.erl
+++ b/lib/stdlib/test/unicode_util_SUITE.erl
@@ -310,12 +310,23 @@ get(_) ->
add_get_tests.
count(Config) ->
+ Parent = self(),
+ Exec = fun() ->
+ do_measure(Config),
+ Parent ! {test_done, self()}
+ end,
ct:timetrap({minutes,5}),
case ct:get_timetrap_info() of
{_,{_,Scale}} when Scale > 1 ->
{skip,{measurments_skipped_debug,Scale}};
- _ -> % No scaling
- do_measure(Config)
+ _ -> % No scaling, run at most 2 min
+ Tester = spawn(Exec),
+ receive {test_done, Tester} -> ok
+ after 120000 ->
+ io:format("Timelimit reached stopping~n",[]),
+ exit(Tester, die)
+ end,
+ ok
end.
do_measure(Config) ->