From 45f779b2e8dfef5c357c8276096626ecb55acc7c Mon Sep 17 00:00:00 2001 From: Kevin De Pelseneer Date: Wed, 15 May 2024 14:38:09 +0200 Subject: [PATCH] Restore the internalisation settings afterwards --- test/functional/homes_controller_test.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/functional/homes_controller_test.rb b/test/functional/homes_controller_test.rb index 0c3ca05d19..a8bbc1c54f 100644 --- a/test/functional/homes_controller_test.rb +++ b/test/functional/homes_controller_test.rb @@ -727,6 +727,7 @@ class HomesControllerTest < ActionController::TestCase end test 'Show aliases in search options' do + original_load_path = I18n.load_path I18n.load_path += Dir[Rails.root.join('test', 'config', 'translation_override.en.yml')] I18n.backend.load_translations with_config_values({ isa_json_compliance_enabled: true, solr_enabled: true }) do @@ -769,6 +770,8 @@ class HomesControllerTest < ActionController::TestCase assert_select 'option', text: 'Programmes', count: 0 end end + I18n.load_path = original_load_path + I18n.backend.load_translations end test 'get dataset jsonld from index' do