diff options
author | Siri Hansen <[email protected]> | 2014-06-11 15:07:43 +0200 |
---|---|---|
committer | Siri Hansen <[email protected]> | 2014-06-11 15:07:43 +0200 |
commit | 7274a9db9b17cc14fde15a3aa0574136c58e8551 (patch) | |
tree | 784af5ebfb48de90041e82569d94fbf4964b670c /lib/common_test/test/ct_cover_SUITE.erl | |
parent | fed8c2586a80c79951f994f24ba69c30bd8d262c (diff) | |
parent | 5a3c4668908254ee930c8db2e5cf9741945f9b2b (diff) | |
download | otp-7274a9db9b17cc14fde15a3aa0574136c58e8551.tar.gz otp-7274a9db9b17cc14fde15a3aa0574136c58e8551.tar.bz2 otp-7274a9db9b17cc14fde15a3aa0574136c58e8551.zip |
Merge branch 'siri/ct-and-cover/OTP-11971' into maint
* siri/ct-and-cover/OTP-11971:
Improve cover analysis via common_test
Change internal format of CoverInfo in test_server
[ct] Add test of cover support when merge_tests=false
Diffstat (limited to 'lib/common_test/test/ct_cover_SUITE.erl')
-rw-r--r-- | lib/common_test/test/ct_cover_SUITE.erl | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/lib/common_test/test/ct_cover_SUITE.erl b/lib/common_test/test/ct_cover_SUITE.erl index ec2680f664..47080b5577 100644 --- a/lib/common_test/test/ct_cover_SUITE.erl +++ b/lib/common_test/test/ct_cover_SUITE.erl @@ -172,8 +172,8 @@ cross(Config) -> check_calls(Events2,1), %% Get the log dirs for each test and run cross cover analyse - [D11,D12] = lists:sort(get_run_dirs(Events1)), - [D21,D22] = lists:sort(get_run_dirs(Events2)), + [D11,D12] = lists:sort(get_log_dirs(Events1)), + [D21,D22] = lists:sort(get_log_dirs(Events2)), ct_cover:cross_cover_analyse(details,[{cross1,D11},{cross2,D21}]), ct_cover:cross_cover_analyse(details,[{cross1,D12},{cross2,D22}]), @@ -267,18 +267,17 @@ check_cover(Node) when is_atom(Node) -> false end. -%% Get the log dir "run.<timestamp>" for all (both!) tests -get_run_dirs(Events) -> - [filename:dirname(TCLog) || +%% Get the log dir "ct_run.<timestamp>" for all (both!) tests +get_log_dirs(Events) -> + [LogDir || {ct_test_support_eh, - {event,tc_logfile,_Node, - {{?suite,init_per_suite},TCLog}}} <- Events]. + {event,start_logging,_Node,LogDir}} <- Events]. %% Check that each coverlog includes N calls to ?mod:foo/0 check_calls(Events,N) -> check_calls(Events,{?mod,foo,0},N). check_calls(Events,MFA,N) -> - CoverLogs = [filename:join(D,"all.coverdata") || D <- get_run_dirs(Events)], + CoverLogs = [filename:join(D,"all.coverdata") || D <- get_log_dirs(Events)], do_check_logs(CoverLogs,MFA,N). do_check_logs([CoverLog|CoverLogs],{Mod,_,_} = MFA,N) -> |