Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/support/database_cleaner.rb')
-rw-r--r--spec/support/database_cleaner.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/support/database_cleaner.rb b/spec/support/database_cleaner.rb
index 6a0e398daa1..01bf390d9e9 100644
--- a/spec/support/database_cleaner.rb
+++ b/spec/support/database_cleaner.rb
@@ -52,6 +52,8 @@ RSpec.configure do |config|
example.run
delete_from_all_tables!(except: deletion_except_tables)
+
+ self.class.use_transactional_tests = true
end
config.around(:each, :migration) do |example|
@@ -60,5 +62,7 @@ RSpec.configure do |config|
example.run
delete_from_all_tables!
+
+ self.class.use_transactional_tests = true
end
end