We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7deac77 commit 0490b3cCopy full SHA for 0490b3c
spec/support/db_cleaner.rb
@@ -12,7 +12,9 @@
12
# Therefore, they are specified explicitly here.
13
unless WITHOUT_MONGOID
14
require "database_cleaner-mongoid"
15
- DatabaseCleaner[:mongoid].strategy = :deletion, { only: %w[users] }
+ strategy = DatabaseCleaner::Mongoid::Deletion.new(only: %w[users])
16
+ DatabaseCleaner[:mongoid].instance_variable_set :'@strategy', strategy
17
+ DatabaseCleaner[:mongoid].start
18
end
19
20
DatabaseCleaner.clean
0 commit comments