aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/test
diff options
context:
space:
mode:
authorPeter Andersson <[email protected]>2014-01-29 12:03:16 +0100
committerPeter Andersson <[email protected]>2014-01-29 12:03:16 +0100
commit47a9a27ef366474bd0a1f404f81df8359b968a36 (patch)
treec4d2f1fd9af2d9d2a7691e2afea732c84fd1ea24 /lib/common_test/test
parentbf6c2ff6625c45bc6c65c112719879078292ee22 (diff)
downloadotp-47a9a27ef366474bd0a1f404f81df8359b968a36.tar.gz
otp-47a9a27ef366474bd0a1f404f81df8359b968a36.tar.bz2
otp-47a9a27ef366474bd0a1f404f81df8359b968a36.zip
Add verification terms for the unix_telnet test case
Diffstat (limited to 'lib/common_test/test')
-rw-r--r--lib/common_test/test/ct_telnet_SUITE.erl43
1 files changed, 34 insertions, 9 deletions
diff --git a/lib/common_test/test/ct_telnet_SUITE.erl b/lib/common_test/test/ct_telnet_SUITE.erl
index 33b343e9ff..25debf09d4 100644
--- a/lib/common_test/test/ct_telnet_SUITE.erl
+++ b/lib/common_test/test/ct_telnet_SUITE.erl
@@ -205,22 +205,47 @@ events_to_check(timetrap,_Config) ->
{?eh,tc_done,{ct_telnet_timetrap_SUITE,expect_success,ok}},
{?eh,stop_logging,[]}].
-%%! THIS MUST BE FIXED!!!
-all_cases(ct_telnet_basic_SUITE,_Config) ->
- [{?eh,start_logging,{'DEF','RUNDIR'}},
- {?eh,stop_logging,[]}];
-
all_cases(Suite,Config) ->
{module,_} = code:load_abs(filename:join(?config(data_dir,Config),
Suite)),
- TCs = Suite:all(),
+ GroupsAndTCs = Suite:all(),
+
+ Terms =
+ lists:flatmap(
+ fun({group,G}) ->
+ {value,{G,Props,GTCs}} =
+ lists:keysearch(G,1,Suite:groups()),
+ GTCs1 = case lists:member(parallel,Props) of
+ true ->
+ %%! TEMPORARY WORKAROUND FOR PROBLEM
+ %%! WITH ct_test_support NOT HANDLING
+ %%! VERIFICATION OF PARALLEL GROUPS
+ %%! CORRECTLY!
+ [];
+ false ->
+ [[{?eh,tc_start,{Suite,GTC}},
+ {?eh,tc_done,{Suite,GTC,ok}}] ||
+ GTC <- GTCs]
+ end,
+ [{?eh,tc_start,{Suite,{init_per_group,G,Props}}},
+ {?eh,tc_done,{Suite,{init_per_group,G,Props},ok}} |
+ GTCs1] ++
+ [{?eh,tc_start,{Suite,{end_per_group,G,Props}}},
+ {?eh,tc_done,{Suite,{end_per_group,G,Props},ok}}];
+ (TC) ->
+ [{?eh,tc_done,{Suite,TC,ok}}]
+ end, GroupsAndTCs),
+
code:purge(Suite),
code:delete(Suite),
+ FlatTerms = lists:flatten(Terms),
+
+ ct:log("Verifying with terms:~n~p", [FlatTerms]),
+
OneTest =
- [{?eh,start_logging,{'DEF','RUNDIR'}}] ++
- [{?eh,tc_done,{Suite,TC,ok}} || TC <- TCs] ++
- [{?eh,stop_logging,[]}],
+ [{?eh,start_logging,{'DEF','RUNDIR'}} |
+ FlatTerms] ++ [{?eh,stop_logging,[]}],
%% 2 tests (ct:run_test + script_start) is default
OneTest ++ OneTest.