diff options
author | Hans Bolinder <[email protected]> | 2017-09-21 08:01:52 +0200 |
---|---|---|
committer | Hans Bolinder <[email protected]> | 2017-09-21 08:01:52 +0200 |
commit | f150c21029477836fb4b533ee02290d5b6bcc818 (patch) | |
tree | 45b5a86849d3d870739e3080e2184459e6929539 /lib/tools/test/fprof_SUITE.erl | |
parent | 79bd54e898c65f8b649d56525db214386cc75cf8 (diff) | |
parent | 918e7de543f729b6fad35c22eaeeb3fba3a4a7ba (diff) | |
download | otp-f150c21029477836fb4b533ee02290d5b6bcc818.tar.gz otp-f150c21029477836fb4b533ee02290d5b6bcc818.tar.bz2 otp-f150c21029477836fb4b533ee02290d5b6bcc818.zip |
Merge branch 'hasse/tools/fprof_unicode_fix' into maint
* hasse/tools/fprof_unicode_fix:
fprof: Make sure the receiving file can handle Unicode
Diffstat (limited to 'lib/tools/test/fprof_SUITE.erl')
-rw-r--r-- | lib/tools/test/fprof_SUITE.erl | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/lib/tools/test/fprof_SUITE.erl b/lib/tools/test/fprof_SUITE.erl index affb45b7a6..8fd164a4b3 100644 --- a/lib/tools/test/fprof_SUITE.erl +++ b/lib/tools/test/fprof_SUITE.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 2001-2016. All Rights Reserved. +%% Copyright Ericsson AB 2001-2017. All Rights Reserved. %% %% Licensed under the Apache License, Version 2.0 (the "License"); %% you may not use this file except in compliance with the License. @@ -27,7 +27,7 @@ %% Test suites -export([stack_seq/1, tail_seq/1, create_file_slow/1, spawn_simple/1, imm_tail_seq/1, imm_create_file_slow/1, imm_compile/1, - cpu_create_file_slow/1]). + cpu_create_file_slow/1, unicode/1]). %% Other exports -export([create_file_slow/2]). @@ -59,7 +59,7 @@ all() -> false -> [stack_seq, tail_seq, create_file_slow, spawn_simple, imm_tail_seq, imm_create_file_slow, imm_compile, - cpu_create_file_slow] + cpu_create_file_slow, unicode] end. @@ -533,6 +533,17 @@ cpu_create_file_slow(Config) when is_list(Config) -> TestResult. +unicode(Config) when is_list(Config) -> + DataDir = proplists:get_value(data_dir, Config), + SourceFile = filename:join(DataDir, "fprof_unicode.erl"), + PrivDir = proplists:get_value(priv_dir, Config), + AnalysisFile = filename:join(PrivDir, "fprof_unicode.analysis"), + {ok, fprof_unicode} = compile:file(SourceFile, [{outdir, PrivDir}]), + true = code:add_path(PrivDir), + fprof:apply(fprof_unicode, t, []), + ok = fprof:profile(dump, AnalysisFile), + ok = fprof:analyse(dest, AnalysisFile). + %%%--------------------------------------------------------------------- %%% Functions to test %%%--------------------------------------------------------------------- |