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
path: root/config
diff options
context:
space:
mode:
authorHeinrich Lee Yu <heinrich@gitlab.com>2019-04-26 18:49:19 +0300
committerHeinrich Lee Yu <heinrich@gitlab.com>2019-07-12 05:39:14 +0300
commitd4a919679a1eb5d3e2aaed4b920e6027d2482971 (patch)
treecdaaeb66e7de69a71994e08dd65478cab364fa24 /config
parentecffca5d92353d55aaf8f984737fa617782310e0 (diff)
Use transactions in JS feature specs
Uses Rails transactional tests instead of DatabaseCleaner transaction strategy because that doesn't work with JS tests
Diffstat (limited to 'config')
-rw-r--r--config/environments/test.rb2
-rw-r--r--config/initializers/active_record_query_cache.rb3
2 files changed, 4 insertions, 1 deletions
diff --git a/config/environments/test.rb b/config/environments/test.rb
index e7166882eea..bd35bdd8d5a 100644
--- a/config/environments/test.rb
+++ b/config/environments/test.rb
@@ -40,7 +40,7 @@ Rails.application.configure do
# Print deprecation notices to the stderr
config.active_support.deprecation = :stderr
- config.eager_load = false
+ config.eager_load = true
config.cache_store = :null_store
diff --git a/config/initializers/active_record_query_cache.rb b/config/initializers/active_record_query_cache.rb
new file mode 100644
index 00000000000..61505a1edd3
--- /dev/null
+++ b/config/initializers/active_record_query_cache.rb
@@ -0,0 +1,3 @@
+# frozen_string_literal: true
+
+ActiveRecord::ConnectionAdapters::ConnectionPool.prepend Gitlab::Patch::ActiveRecordQueryCache