diff options
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/database_cleaner.rb | 10 | ||||
-rw-r--r-- | spec/support/migration.rb | 2 |
2 files changed, 2 insertions, 10 deletions
diff --git a/spec/support/database_cleaner.rb b/spec/support/database_cleaner.rb index 222cbe9feeb..7bd1f0c5dfa 100644 --- a/spec/support/database_cleaner.rb +++ b/spec/support/database_cleaner.rb @@ -22,14 +22,4 @@ RSpec.configure do |config| self.class.use_transactional_tests = true end - - config.around(:each, :migration) do |example| - self.class.use_transactional_tests = false - - example.run - - delete_from_all_tables!(except: deletion_except_tables) - - self.class.use_transactional_tests = true - end end diff --git a/spec/support/migration.rb b/spec/support/migration.rb index 2a69630a29a..4d4a293e9ff 100644 --- a/spec/support/migration.rb +++ b/spec/support/migration.rb @@ -45,6 +45,8 @@ RSpec.configure do |config| example.run end + delete_from_all_tables!(except: deletion_except_tables) + self.class.use_transactional_tests = true end |