Skip to content

Commit a57f62e

Browse files
committed
Refactor rabbitmq_consistent_hash_exchange bazel
1 parent ec5954f commit a57f62e

File tree

1 file changed

+12
-40
lines changed

1 file changed

+12
-40
lines changed
Lines changed: 12 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1-
load("@bazel-erlang//:ct.bzl", "ct_suite")
2-
load("//:rabbitmq_home.bzl", "rabbitmq_home")
3-
load("//:rabbitmq_run.bzl", "rabbitmq_run")
4-
load("//:rabbitmq.bzl", "APP_VERSION", "RABBITMQ_TEST_ERLC_OPTS", "rabbitmq_lib")
1+
load(
2+
"//:rabbitmq.bzl",
3+
"APP_VERSION",
4+
"RABBITMQ_TEST_ERLC_OPTS",
5+
"broker_for_integration_suites",
6+
"rabbitmq_integration_suite",
7+
"rabbitmq_lib",
8+
)
59

610
APP_NAME = "rabbitmq_consistent_hash_exchange"
711

@@ -28,43 +32,11 @@ rabbitmq_lib(
2832
deps = DEPS,
2933
)
3034

31-
rabbitmq_home(
32-
name = "broker-for-tests-home",
33-
plugins = [
34-
"//deps/rabbit:bazel_erlang_lib",
35-
":bazel_erlang_lib",
36-
],
37-
)
35+
broker_for_integration_suites()
3836

39-
rabbitmq_run(
40-
name = "rabbitmq-for-tests-run",
41-
home = ":broker-for-tests-home",
42-
)
37+
PACKAGE = "deps/rabbitmq_consistent_hash_exchange"
4338

44-
ct_suite(
39+
rabbitmq_integration_suite(
40+
PACKAGE,
4541
name = "rabbit_exchange_type_consistent_hash_SUITE",
46-
data = [
47-
"@rabbitmq_ct_helpers//tools/tls-certs:Makefile",
48-
"@rabbitmq_ct_helpers//tools/tls-certs:openssl.cnf.in",
49-
],
50-
erlc_opts = RABBITMQ_TEST_ERLC_OPTS,
51-
test_env = {
52-
"RABBITMQ_CT_SKIP_AS_ERROR": "true",
53-
"RABBITMQ_RUN": "$TEST_SRCDIR/$TEST_WORKSPACE/deps/rabbitmq_consistent_hash_exchange/rabbitmq-for-tests-run",
54-
"RABBITMQCTL": "$TEST_SRCDIR/$TEST_WORKSPACE/deps/rabbitmq_consistent_hash_exchange/broker-for-tests-home/sbin/rabbitmqctl",
55-
"RABBITMQ_PLUGINS": "$TEST_SRCDIR/$TEST_WORKSPACE/deps/rabbitmq_consistent_hash_exchange/broker-for-tests-home/sbin/rabbitmq-plugins",
56-
},
57-
tools = [
58-
":rabbitmq-for-tests-run",
59-
],
60-
runtime_deps = [
61-
"//deps/rabbitmq_cli:elixir_as_bazel_erlang_lib",
62-
"//deps/rabbitmq_cli:rabbitmqctl",
63-
"@rabbitmq_ct_client_helpers//:bazel_erlang_lib",
64-
"@rabbitmq_ct_helpers//:bazel_erlang_lib",
65-
],
66-
deps = [
67-
"//deps/amqp_client:bazel_erlang_lib",
68-
"//deps/rabbit_common:bazel_erlang_lib",
69-
],
7042
)

0 commit comments

Comments
 (0)