LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File 0606-code_SUITE-Always-disable-tracing-after-upgrade-test.patch of Package erlang (Project home:Ledest:erlang:20)

From c6b5df425ec825c041e666351b1466e4d3feb859 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?John=20H=C3=B6gberg?= <john@erlang.org>
Date: Tue, 19 Mar 2019 09:01:20 +0100
Subject: [PATCH 2/2] code_SUITE: Always disable tracing after 'upgrade' test

Tracing would be left hanging if the test timed out, causing later
tests to fail.
---
 lib/kernel/test/code_SUITE.erl | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/kernel/test/code_SUITE.erl b/lib/kernel/test/code_SUITE.erl
index f5c1864b3e..99fecbe970 100644
--- a/lib/kernel/test/code_SUITE.erl
+++ b/lib/kernel/test/code_SUITE.erl
@@ -140,6 +140,11 @@ end_per_testcase(on_load_embedded, Config) ->
     LinkName = proplists:get_value(link_name, Config),
     _ = del_link(LinkName),
     end_per_testcase(Config);
+end_per_testcase(upgrade, Config) ->
+    %% Make sure tracing is turned off even if the test times out.
+    erlang:trace_pattern({error_handler,undefined_function,3}, false, [global]),
+    erlang:trace(self(), false, [call]),
+    end_per_testcase(Config);
 end_per_testcase(_Func, Config) ->
     end_per_testcase(Config).
 
-- 
2.16.4