From 185d207aad36516532d47d0ec718078e821a5064 Mon Sep 17 00:00:00 2001 From: Simon MacMullen Date: Thu, 15 Apr 2010 18:09:53 +0100 Subject: Make start-secondary-cover actually do something, stop Erlang tests blowing up. --- Makefile | 2 +- src/rabbit_tests.erl | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 8457cb31..690cb955 100644 --- a/Makefile +++ b/Makefile @@ -157,7 +157,7 @@ start-cover: all echo "cover:start(), rabbit_misc:enable_cover([\"$(COVER_DIR)\"])." | $(ERL_CALL) start-secondary-cover: - echo "rabbit_misc:enable_cover_node(\"$(SECONDARY_NODENAME)\")." | $(ERL_CALL) + echo "rabbit_misc:enable_cover_node(\"$(SECONDARY_NODENAME)\")." | $(ERL_CALL) stop-cover: all echo "rabbit_misc:report_cover(), cover:stop()." | $(ERL_CALL) diff --git a/src/rabbit_tests.erl b/src/rabbit_tests.erl index f7060b0f..58887f2a 100644 --- a/src/rabbit_tests.erl +++ b/src/rabbit_tests.erl @@ -650,8 +650,12 @@ test_cluster_management2(SecondaryNode) -> ok = control_action(stop_app, []), %% NB: this will log an inconsistent_database error, which is harmless + %% Turning cover on / off is OK even if we're not in general using cover, + %% it just turns the engine on / off, doesn't actually log anything. + cover:stop([SecondaryNode]), true = disconnect_node(SecondaryNode), pong = net_adm:ping(SecondaryNode), + cover:start([SecondaryNode]), %% leaving a cluster as a ram node ok = control_action(reset, []), -- cgit v1.2.1