Skip to content
Snippets Groups Projects
Commit 27a01824 authored by Thong Kuah's avatar Thong Kuah
Browse files

Merge branch 'sh-consolidate-migration-delete' into 'master'

Consolidate database cleaner code for migrations

See merge request https://gitlab.com/gitlab-org/gitlab/-/merge_requests/105600



Merged-by: default avatarThong Kuah <tkuah@gitlab.com>
Approved-by: default avatarKrasimir Angelov <kangelov@gitlab.com>
Approved-by: default avatarThong Kuah <tkuah@gitlab.com>
Co-authored-by: default avatarStan Hu <stanhu@gmail.com>
parents 2ed4d39a d665e227
No related merge requests found
......@@ -22,14 +22,4 @@
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
......@@ -45,6 +45,8 @@
example.run
end
delete_from_all_tables!(except: deletion_except_tables)
self.class.use_transactional_tests = true
end
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment