Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
d19bd189
Commit
d19bd189
authored
Nov 28, 2019
by
Luke Duncalfe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove design_management_flag feature flag
https://gitlab.com/gitlab-org/gitlab/issues/13709
parent
15136629
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
29 deletions
+16
-29
ee/app/models/ee/project.rb
ee/app/models/ee/project.rb
+1
-6
ee/changelogs/unreleased/13709-remove-design-management-flag.yml
...gelogs/unreleased/13709-remove-design-management-flag.yml
+7
-0
ee/spec/features/issues/issues_tabs_spec.rb
ee/spec/features/issues/issues_tabs_spec.rb
+0
-2
ee/spec/models/project_spec.rb
ee/spec/models/project_spec.rb
+8
-9
ee/spec/policies/design_management/design_policy_spec.rb
ee/spec/policies/design_management/design_policy_spec.rb
+0
-12
No files found.
ee/app/models/ee/project.rb
View file @
d19bd189
...
@@ -663,12 +663,7 @@ module EE
...
@@ -663,12 +663,7 @@ module EE
# hashed storage requirement for existing design management projects.
# hashed storage requirement for existing design management projects.
# See https://gitlab.com/gitlab-org/gitlab/issues/13428#note_238729038
# See https://gitlab.com/gitlab-org/gitlab/issues/13428#note_238729038
(
hashed_storage?
(
:repository
)
||
::
Feature
.
disabled?
(
:design_management_require_hashed_storage
,
self
,
default_enabled:
true
))
&&
(
hashed_storage?
(
:repository
)
||
::
Feature
.
disabled?
(
:design_management_require_hashed_storage
,
self
,
default_enabled:
true
))
&&
# Check both feature availability on the license, as well as the feature
feature_available?
(
:design_management
)
# flag, because we don't want to enable design_management by default on
# on prem installs yet.
# See https://gitlab.com/gitlab-org/gitlab/issues/13709
feature_available?
(
:design_management
)
&&
::
Feature
.
enabled?
(
:design_management_flag
,
self
,
default_enabled:
true
)
end
end
def
design_repository
def
design_repository
...
...
ee/changelogs/unreleased/13709-remove-design-management-flag.yml
0 → 100644
View file @
d19bd189
---
title
:
Remove the design_management_flag feature flag from the codebase. The feature
flag toggles the Design Management feature, and has been enabled by default since
12.2.
merge_request
:
20883
author
:
type
:
other
ee/spec/features/issues/issues_tabs_spec.rb
View file @
d19bd189
...
@@ -9,8 +9,6 @@ describe 'Issue page tabs', :js do
...
@@ -9,8 +9,6 @@ describe 'Issue page tabs', :js do
describe
'discussions tab counter'
do
describe
'discussions tab counter'
do
before
do
before
do
stub_licensed_features
(
design_management:
true
)
stub_feature_flags
(
design_management_flag:
true
)
allow
(
Ability
).
to
receive
(
:allowed?
)
{
true
}
allow
(
Ability
).
to
receive
(
:allowed?
)
{
true
}
end
end
...
...
ee/spec/models/project_spec.rb
View file @
d19bd189
...
@@ -1903,20 +1903,19 @@ describe Project do
...
@@ -1903,20 +1903,19 @@ describe Project do
describe
'#design_management_enabled?'
do
describe
'#design_management_enabled?'
do
let
(
:project
)
{
build
(
:project
)
}
let
(
:project
)
{
build
(
:project
)
}
where
(
:feature_enabled
,
:license_enabled
,
:lfs_enabled
,
:hashed_storage_enabled
,
:hash_storage_required
,
:expectation
)
do
where
(
:license_enabled
,
:lfs_enabled
,
:hashed_storage_enabled
,
:hash_storage_required
,
:expectation
)
do
false
|
false
|
false
|
false
|
false
|
false
false
|
false
|
false
|
false
|
false
true
|
false
|
false
|
false
|
false
|
false
true
|
false
|
false
|
false
|
false
true
|
true
|
false
|
false
|
false
|
false
true
|
true
|
false
|
false
|
true
true
|
true
|
true
|
false
|
false
|
true
true
|
true
|
false
|
true
|
false
true
|
true
|
true
|
false
|
true
|
false
true
|
true
|
true
|
false
|
true
true
|
true
|
true
|
true
|
false
|
true
true
|
true
|
true
|
true
|
true
true
|
true
|
true
|
true
|
true
|
true
end
end
with_them
do
with_them
do
before
do
before
do
stub_licensed_features
(
design_management:
license_enabled
)
stub_licensed_features
(
design_management:
license_enabled
)
stub_feature_flags
(
design_management_
flag:
feature_enabled
,
design_management_
require_hashed_storage:
hash_storage_required
)
stub_feature_flags
(
design_management_require_hashed_storage:
hash_storage_required
)
expect
(
project
).
to
receive
(
:lfs_enabled?
).
and_return
(
lfs_enabled
)
expect
(
project
).
to
receive
(
:lfs_enabled?
).
and_return
(
lfs_enabled
)
allow
(
project
).
to
receive
(
:hashed_storage?
).
with
(
:repository
).
and_return
(
hashed_storage_enabled
)
allow
(
project
).
to
receive
(
:hashed_storage?
).
with
(
:repository
).
and_return
(
hashed_storage_enabled
)
end
end
...
...
ee/spec/policies/design_management/design_policy_spec.rb
View file @
d19bd189
...
@@ -99,20 +99,9 @@ describe DesignManagement::DesignPolicy do
...
@@ -99,20 +99,9 @@ describe DesignManagement::DesignPolicy do
it
{
is_expected
.
to
be_disallowed
(
:create_design
,
:destroy_design
)
}
it
{
is_expected
.
to
be_disallowed
(
:create_design
,
:destroy_design
)
}
end
end
context
"when the feature flag is off"
do
before
do
stub_licensed_features
(
design_management:
true
)
stub_feature_flags
(
design_management_flag:
false
)
allow
(
Gitlab
.
config
.
lfs
).
to
receive
(
:enabled
).
and_return
(
true
)
end
it_behaves_like
"design abilities not available"
end
context
"when the license does not include the feature"
do
context
"when the license does not include the feature"
do
before
do
before
do
stub_licensed_features
(
design_management:
false
)
stub_licensed_features
(
design_management:
false
)
stub_feature_flags
(
design_management_flag:
true
)
allow
(
Gitlab
.
config
.
lfs
).
to
receive
(
:enabled
).
and_return
(
true
)
allow
(
Gitlab
.
config
.
lfs
).
to
receive
(
:enabled
).
and_return
(
true
)
end
end
...
@@ -122,7 +111,6 @@ describe DesignManagement::DesignPolicy do
...
@@ -122,7 +111,6 @@ describe DesignManagement::DesignPolicy do
context
"when LFS is not enabled"
do
context
"when LFS is not enabled"
do
before
do
before
do
stub_licensed_features
(
design_management:
true
)
stub_licensed_features
(
design_management:
true
)
stub_feature_flags
(
design_management_flag:
true
)
allow
(
Gitlab
.
config
.
lfs
).
to
receive
(
:enabled
).
and_return
(
false
)
allow
(
Gitlab
.
config
.
lfs
).
to
receive
(
:enabled
).
and_return
(
false
)
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment