~ubuntu-branches/ubuntu/trusty/erlang/trusty

« back to all changes in this revision

Viewing changes to erts/emulator/test/trace_local_SUITE.erl

  • Committer: Bazaar Package Importer
  • Author(s): Clint Byrum
  • Date: 2011-05-05 15:48:43 UTC
  • mfrom: (3.5.13 sid)
  • Revision ID: james.westby@ubuntu.com-20110505154843-0om6ekzg6m7ugj27
Tags: 1:14.b.2-dfsg-3ubuntu1
* Merge from debian unstable.  Remaining changes:
  - Drop libwxgtk2.8-dev build dependency. Wx isn't in main, and not
    supposed to.
  - Drop erlang-wx binary.
  - Drop erlang-wx dependency from -megaco, -common-test, and -reltool, they
    do not really need wx. Also drop it from -debugger; the GUI needs wx,
    but it apparently has CLI bits as well, and is also needed by -megaco,
    so let's keep the package for now.
  - debian/patches/series: Do what I meant, and enable build-options.patch
    instead.
* Additional changes:
  - Drop erlang-wx from -et
* Dropped Changes:
  - patches/pcre-crash.patch: CVE-2008-2371: outer level option with
    alternatives caused crash. (Applied Upstream)
  - fix for ssl certificate verification in newSSL: 
    ssl_cacertfile_fix.patch (Applied Upstream)
  - debian/patches/series: Enable native.patch again, to get stripped beam
    files and reduce the package size again. (build-options is what
    actually accomplished this)
  - Remove build-options.patch on advice from upstream and because it caused
    odd build failures.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
%%
2
2
%% %CopyrightBegin%
3
3
%% 
4
 
%% Copyright Ericsson AB 2000-2009. All Rights Reserved.
 
4
%% Copyright Ericsson AB 2000-2011. All Rights Reserved.
5
5
%% 
6
6
%% The contents of this file are subject to the Erlang Public License,
7
7
%% Version 1.1, (the "License"); you may not use this file except in
45
45
-export([config/2]).
46
46
-define(DEFAULT_RECEIVE_TIMEOUT, 1000).
47
47
-else.
48
 
-include("test_server.hrl").
 
48
-include_lib("test_server/include/test_server.hrl").
49
49
-define(DEFAULT_RECEIVE_TIMEOUT, infinity).
50
50
-endif.
51
51
 
68
68
 
69
69
%%% When run in test server %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
70
70
 
71
 
-export([all/1, basic/1, bit_syntax/1,
 
71
-export([all/0, suite/0,groups/0,init_per_suite/1, end_per_suite/1, 
 
72
         init_per_group/2,end_per_group/2, basic/1, bit_syntax/1,
72
73
         return/1, on_and_off/1, stack_grow/1,info/1, delete/1,
73
74
         exception/1, exception_apply/1,
74
75
         exception_function/1, exception_apply_function/1,
79
80
         exception_meta_nocatch/1, exception_meta_nocatch_apply/1,
80
81
         exception_meta_nocatch_function/1,
81
82
         exception_meta_nocatch_apply_function/1,
82
 
         init_per_testcase/2, fin_per_testcase/2]).
 
83
         init_per_testcase/2, end_per_testcase/2]).
83
84
init_per_testcase(_Case, Config) ->
84
85
    ?line Dog=test_server:timetrap(test_server:minutes(2)),
85
86
    [{watchdog, Dog}|Config].
86
87
 
87
 
fin_per_testcase(_Case, Config) ->
 
88
end_per_testcase(_Case, Config) ->
88
89
    shutdown(),
89
90
    Dog=?config(watchdog, Config),
90
91
    test_server:timetrap_cancel(Dog),
91
92
    ok.
92
 
all(doc) ->
93
 
    ["Test tracing of local function calls and return traces."];
94
 
all(suite) ->
95
 
    case test_server:is_native(?MODULE) of
 
93
suite() -> [{ct_hooks,[ts_install_cth]}].
 
94
 
 
95
all() -> 
 
96
    case test_server:is_native(trace_local_SUITE) of
96
97
        true -> [not_run];
97
 
        false -> [basic, bit_syntax, return, on_and_off, stack_grow, info, delete,
98
 
                  exception, exception_apply,
99
 
                  exception_function, exception_apply_function,
100
 
                  exception_nocatch, exception_nocatch_apply,
101
 
                  exception_nocatch_function, 
102
 
                  exception_nocatch_apply_function,
103
 
                  exception_meta, exception_meta_apply,
104
 
                  exception_meta_function, exception_meta_apply_function,
105
 
                  exception_meta_nocatch, exception_meta_nocatch_apply,
106
 
                  exception_meta_nocatch_function,
107
 
                  exception_meta_nocatch_apply_function]
 
98
        false ->
 
99
            [basic, bit_syntax, return, on_and_off, stack_grow,
 
100
             info, delete, exception, exception_apply,
 
101
             exception_function, exception_apply_function,
 
102
             exception_nocatch, exception_nocatch_apply,
 
103
             exception_nocatch_function,
 
104
             exception_nocatch_apply_function, exception_meta,
 
105
             exception_meta_apply, exception_meta_function,
 
106
             exception_meta_apply_function, exception_meta_nocatch,
 
107
             exception_meta_nocatch_apply,
 
108
             exception_meta_nocatch_function,
 
109
             exception_meta_nocatch_apply_function]
108
110
    end.
109
111
 
 
112
groups() -> 
 
113
    [].
 
114
 
 
115
init_per_suite(Config) ->
 
116
    Config.
 
117
 
 
118
end_per_suite(_Config) ->
 
119
    ok.
 
120
 
 
121
init_per_group(_GroupName, Config) ->
 
122
    Config.
 
123
 
 
124
end_per_group(_GroupName, Config) ->
 
125
    Config.
 
126
 
 
127
 
110
128
not_run(Config) when is_list(Config) -> 
111
129
    {skipped,"Native code"}.
112
130
 
796
814
loop(D1,D2,D3,N) ->
797
815
    max(N,loop(D1,D2,D3,N-1)).
798
816
 
799
 
max(A, B) when A > B -> A;
800
 
max(_, B) -> B.
801
 
 
802
817
exported_wrap(Val) ->
803
818
    exported(Val).
804
819