Skip to content

Commit e295b5d

Browse files
committed
more
1 parent 176d30f commit e295b5d

3 files changed

Lines changed: 11 additions & 3 deletions

File tree

spec/integration/automatic_reconnect_spec.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ def spoke
1212
default_routes_for GusSubscriber
1313
end
1414
end
15-
let(:http_client) { RabbitMQ::HTTP::Client.new("http://127.0.0.1:15672") }
15+
let(:rabbitmq_host) {
16+
ENV["RABBITMQ_HOST"] || "127.0.0.1"
17+
}
18+
let(:http_client) { RabbitMQ::HTTP::Client.new("http://#{rabbitmq_host}:15672") }
1619
let(:subscriber) { GusSubscriber }
1720

1821
it "reconnects when a connection drops" do

spec/integration/consumer_cancellation_spec.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@ def created
1313
default_routes_for ::YoloSubscriber
1414
end
1515
end
16-
let(:http_client) { ::RabbitMQ::HTTP::Client.new("http://127.0.0.1:15672") }
16+
17+
let(:rabbitmq_host) {
18+
ENV["RABBITMQ_HOST"] || "127.0.0.1"
19+
}
20+
let(:http_client) { ::RabbitMQ::HTTP::Client.new("http://#{rabbitmq_host}:15672") }
1721
let(:subscriber) { ::YoloSubscriber }
1822

1923
it "resubscribes on cancellation" do

spec/spec_helper.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@
2424
$TESTING = true
2525
::ActionSubscriber::Logging.initialize_logger(nil)
2626
::ActionSubscriber.setup_default_threadpool!
27-
# setup active publisher
27+
28+
# load from action_subscriber.yml for both ActivePublisher and ActionSubscriber
2829
::ActivePublisher::Configuration.configure_from_yaml_and_cli
2930
::ActionSubscriber::Configuration.configure_from_yaml_and_cli
3031

0 commit comments

Comments
 (0)