summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Sébastien Pédron <jean-sebastien@rabbitmq.com>2020-03-31 16:27:20 +0200
committerJean-Sébastien Pédron <jean-sebastien@rabbitmq.com>2020-04-01 11:38:16 +0200
commit17968ee10787d6dca41790777f6d547fb6e0be78 (patch)
treee1e453e093d7e1d88120c75c0d6185434092f100
parenta503baf6b3c6f4112ea9f22f038b0cb1cb822e39 (diff)
downloadrabbitmq-server-git-17968ee10787d6dca41790777f6d547fb6e0be78.tar.gz
clustering_management_SUITE: No need to stop node after start_app failure
... in `erlang_config`. Since #2180, a failed `start_app` does not take the node down anymore. Trying to restart the node just after was failing since (because the node is still there), but this remained unnoticed so far because the return value of `start_node()` is not checked. However, since rabbitmq/rabbitmq-ct-helpers@c033d9272afaf3575505533c81f1c0c7cfcb6206, the Make recipe which starts the node automatically stops it if the start failed somewhere. This is in order to not leave an unwanted node around. This means that after the failing `rabbit_ct_broker_helpers:start_node()`, the node was effectively stopped this time, leading to the rest of the testcase to fail.
-rw-r--r--test/clustering_management_SUITE.erl15
1 files changed, 3 insertions, 12 deletions
diff --git a/test/clustering_management_SUITE.erl b/test/clustering_management_SUITE.erl
index 6a48fb17ca..e0865ca115 100644
--- a/test/clustering_management_SUITE.erl
+++ b/test/clustering_management_SUITE.erl
@@ -632,35 +632,26 @@ erlang_config(Config) ->
ok = reset(Hare),
ok = rpc:call(Hare, application, set_env,
[rabbit, cluster_nodes, {["Mike's computer"], disc}]),
- %% Rabbit app stops abnormally, node goes down
+ %% Rabbit app stops abnormally
assert_failure(fun () -> start_app(Hare) end),
assert_not_clustered(Rabbit),
%% If we use an invalid node type, the node fails to start.
- %% The Erlang VM has stopped after previous rabbit app failure
- rabbit_ct_broker_helpers:start_node(Config, Hare),
- ok = stop_app(Hare),
ok = reset(Hare),
ok = rpc:call(Hare, application, set_env,
[rabbit, cluster_nodes, {[Rabbit], blue}]),
- %% Rabbit app stops abnormally, node goes down
+ %% Rabbit app stops abnormally
assert_failure(fun () -> start_app(Hare) end),
assert_not_clustered(Rabbit),
%% If we use an invalid cluster_nodes conf, the node fails to start.
- %% The Erlang VM has stopped after previous rabbit app failure
- rabbit_ct_broker_helpers:start_node(Config, Hare),
- ok = stop_app(Hare),
ok = reset(Hare),
ok = rpc:call(Hare, application, set_env,
[rabbit, cluster_nodes, true]),
- %% Rabbit app stops abnormally, node goes down
+ %% Rabbit app stops abnormally
assert_failure(fun () -> start_app(Hare) end),
assert_not_clustered(Rabbit),
- %% The Erlang VM has stopped after previous rabbit app failure
- rabbit_ct_broker_helpers:start_node(Config, Hare),
- ok = stop_app(Hare),
ok = reset(Hare),
ok = rpc:call(Hare, application, set_env,
[rabbit, cluster_nodes, "Yes, please"]),