summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--features/support/db_cleaner.rb2
-rw-r--r--spec/support/db_cleaner.rb6
2 files changed, 4 insertions, 4 deletions
diff --git a/features/support/db_cleaner.rb b/features/support/db_cleaner.rb
index 8294bb1445f..31c922d23c3 100644
--- a/features/support/db_cleaner.rb
+++ b/features/support/db_cleaner.rb
@@ -1,6 +1,6 @@
require 'database_cleaner'
-DatabaseCleaner[:active_record].strategy = :truncation
+DatabaseCleaner[:active_record].strategy = :deletion
Spinach.hooks.before_scenario do
DatabaseCleaner.start
diff --git a/spec/support/db_cleaner.rb b/spec/support/db_cleaner.rb
index edaee03ea6c..7991974499d 100644
--- a/spec/support/db_cleaner.rb
+++ b/spec/support/db_cleaner.rb
@@ -1,10 +1,10 @@
RSpec.configure do |config|
config.before(:suite) do
- DatabaseCleaner.clean_with(:truncation)
+ DatabaseCleaner.clean_with(:deletion)
end
config.append_after(:context) do
- DatabaseCleaner.clean_with(:truncation, cache_tables: false)
+ DatabaseCleaner.clean_with(:deletion, cache_tables: false)
end
config.before(:each) do
@@ -12,7 +12,7 @@ RSpec.configure do |config|
end
config.before(:each, :js) do
- DatabaseCleaner.strategy = :truncation
+ DatabaseCleaner.strategy = :deletion
end
config.before(:each, :truncate) do