mirror of
https://github.com/thoughtbot/factory_bot.git
synced 2022-11-09 11:43:51 -05:00
7722017bc7
Uses a block-based helper so we can remove a global around hook.
10 lines
329 B
Ruby
10 lines
329 B
Ruby
describe "reload" do
|
|
it "does not reset the value of use_parent_strategy" do
|
|
custom_strategy = :custom_use_parent_strategy_value
|
|
|
|
with_temporary_assignment(FactoryBot, :use_parent_strategy, custom_strategy) do
|
|
FactoryBot.reload
|
|
expect(FactoryBot.use_parent_strategy).to eq custom_strategy
|
|
end
|
|
end
|
|
end
|