From 367627a2a30496e71e70ac66aa1a6acd1ee6b554 Mon Sep 17 00:00:00 2001 From: Andrew White Date: Thu, 26 Nov 2020 10:35:59 +0000 Subject: [PATCH] Use host from elasticsearch config hash The DGU Publish application uses the config hash loaded from the config/elasticsearch.yml file so adjust DGU Find to match. --- spec/rails_helper.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 0bcdc8fb..3c36d8d7 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -33,7 +33,10 @@ FactoryBot.find_definitions -WebMock.disable_net_connect!(allow_localhost: true, allow: /^elasticsearch[-a-z0-9]*$/) +WebMock.disable_net_connect!( + allow_localhost: true, + allow: Rails.configuration.elasticsearch["host"], +) RSpec.configure do |config| # RSpec Rails can automatically mix in different behaviours to your tests