diff options
author | Andreas Brandl <abrandl@gitlab.com> | 2019-07-26 09:31:28 +0200 |
---|---|---|
committer | Andreas Brandl <abrandl@gitlab.com> | 2019-07-26 09:37:01 +0200 |
commit | 8bb367a23c36c7f3a2be88c62d99b3f33eb90798 (patch) | |
tree | 9a5e4c64c208a83cf43a351581400e4e66985ac3 | |
parent | 90f0658ca1747f3334f18b118566624c94201a05 (diff) | |
download | gitlab-ce-8bb367a23c36c7f3a2be88c62d99b3f33eb90798.tar.gz |
Re-add code to avoid conflict with other MR
-rw-r--r-- | app/models/concerns/descendant.rb | 3 | ||||
-rw-r--r-- | lib/gitlab/object_hierarchy.rb | 3 | ||||
-rw-r--r-- | spec/spec_helper.rb | 4 |
3 files changed, 6 insertions, 4 deletions
diff --git a/app/models/concerns/descendant.rb b/app/models/concerns/descendant.rb index fd195ae20f5..4c436522122 100644 --- a/app/models/concerns/descendant.rb +++ b/app/models/concerns/descendant.rb @@ -5,8 +5,7 @@ module Descendant class_methods do def supports_nested_objects? - # TODO: Refactor and remove https://gitlab.com/gitlab-org/gitlab-ce/issues/65056 - true + Gitlab::Database.postgresql? end end end diff --git a/lib/gitlab/object_hierarchy.rb b/lib/gitlab/object_hierarchy.rb index e57651dbf64..38b32770e90 100644 --- a/lib/gitlab/object_hierarchy.rb +++ b/lib/gitlab/object_hierarchy.rb @@ -136,8 +136,7 @@ module Gitlab private def hierarchy_supported? - # TODO: Refactor and remove unused method (https://gitlab.com/gitlab-org/gitlab-ce/issues/65055) - true + Gitlab::Database.postgresql? end # rubocop: disable CodeReuse/ActiveRecord diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 94cd944db3d..a44b5069ade 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -262,6 +262,10 @@ RSpec.configure do |config| example.run if Group.supports_nested_objects? end + config.around(:each, :postgresql) do |example| + example.run if Gitlab::Database.postgresql? + end + # This makes sure the `ApplicationController#can?` method is stubbed with the # original implementation for all view specs. config.before(:each, type: :view) do |