diff options
author | Peter Andersson <[email protected]> | 2012-03-06 10:20:14 +0100 |
---|---|---|
committer | Peter Andersson <[email protected]> | 2012-03-06 10:20:14 +0100 |
commit | a8b748b2da23efefcf2761560720c34c916e3873 (patch) | |
tree | 313360dfc1016f9351bd01ff4bb89cbff6762ec1 /lib/test_server | |
parent | f9fcdc3e1278adefc5ada52a163228d6162f7b27 (diff) | |
parent | 2dd629cea2672b227bfce05621aff6c5e65b2a3e (diff) | |
download | otp-a8b748b2da23efefcf2761560720c34c916e3873.tar.gz otp-a8b748b2da23efefcf2761560720c34c916e3873.tar.bz2 otp-a8b748b2da23efefcf2761560720c34c916e3873.zip |
Merge branch 'maint'
Diffstat (limited to 'lib/test_server')
-rw-r--r-- | lib/test_server/src/test_server.erl | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/lib/test_server/src/test_server.erl b/lib/test_server/src/test_server.erl index 51754cb3b4..28ce7c04e7 100644 --- a/lib/test_server/src/test_server.erl +++ b/lib/test_server/src/test_server.erl @@ -1530,8 +1530,18 @@ get_loc(Pid) -> lists:foreach(fun({Key,Val}) -> put(Key, Val) end, Dict), Stk = [rewrite_loc_item(Loc) || Loc <- Stk0], case get(test_server_loc) of - undefined -> put(test_server_loc, Stk); - _ -> ok + undefined -> + put(test_server_loc, Stk); + {Suite,Case} -> + %% location info unknown, check if {Suite,Case,Line} + %% is available in stacktrace. and if so, use stacktrace + %% instead of currect test_server_loc + case [match || {S,C,_L} <- Stk, S == Suite, C == Case] of + [match|_] -> put(test_server_loc, Stk); + _ -> ok + end; + _ -> + ok end, get_loc(). |