From bb584b5382c85b318ec83a98f49d4f4314c5ee83 Mon Sep 17 00:00:00 2001 From: Rui Baltazar Date: Fri, 17 Jul 2020 00:15:19 +0800 Subject: [PATCH] [#92] added comment on test --- spec/examples/generic_adapter_examples.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/spec/examples/generic_adapter_examples.rb b/spec/examples/generic_adapter_examples.rb index 9af74646..e8bf796f 100644 --- a/spec/examples/generic_adapter_examples.rb +++ b/spec/examples/generic_adapter_examples.rb @@ -25,6 +25,8 @@ expect(num_available_connections).to eq(0) end + # NOTE: Bug report #92 - when the adapter is set before the railtie is actually run, the adapter class might be + # incorrect. This tests intends to assure that the railtie init resets the adapter to the correct one it 'ensures apartment_adapter is properly set during init' do Thread.current[:apartment_adapter] = Apartment::Adapters::AbstractAdapter.new(config) Apartment::Railtie.config.to_prepare_blocks.map(&:call)