From c062dfc485ad0d51d648701950f77ef8f51d4f35 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn-Egil=20Dahlberg?= Date: Tue, 8 Mar 2016 19:35:31 +0100 Subject: Modernize use of timetraps --- erts/emulator/test/ref_SUITE.erl | 33 ++++----------------------------- 1 file changed, 4 insertions(+), 29 deletions(-) (limited to 'erts/emulator/test/ref_SUITE.erl') diff --git a/erts/emulator/test/ref_SUITE.erl b/erts/emulator/test/ref_SUITE.erl index 6d4a998094..1bf94b9a3f 100644 --- a/erts/emulator/test/ref_SUITE.erl +++ b/erts/emulator/test/ref_SUITE.erl @@ -20,45 +20,20 @@ -module(ref_SUITE). --export([all/0, suite/0,groups/0,init_per_suite/1, end_per_suite/1, - init_per_group/2,end_per_group/2, - init_per_testcase/2,end_per_testcase/2]). +-export([all/0, suite/0]). -export([wrap_1/1]). -export([loop_ref/1]). -include_lib("common_test/include/ct.hrl"). -init_per_testcase(_, Config) -> - ?line Dog=test_server:timetrap(test_server:minutes(2)), - [{watchdog, Dog}|Config]. - -end_per_testcase(_, Config) -> - Dog=?config(watchdog, Config), - test_server:timetrap_cancel(Dog), - ok. - -suite() -> [{ct_hooks,[ts_install_cth]}]. +suite() -> + [{ct_hooks,[ts_install_cth]}, + {timetrap, {minutes, 2}}]. all() -> [wrap_1]. -groups() -> - []. - -init_per_suite(Config) -> - Config. - -end_per_suite(_Config) -> - ok. - -init_per_group(_GroupName, Config) -> - Config. - -end_per_group(_GroupName, Config) -> - Config. - - wrap_1(doc) -> "Check that refs don't wrap around easily."; wrap_1(Config) when is_list(Config) -> ?line spawn_link(?MODULE, loop_ref, [self()]), -- cgit v1.2.3