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
89880745
Commit
89880745
authored
Dec 03, 2019
by
mo khan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow beta access to licenses list
parent
bea66c38
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
ee/app/policies/ee/project_policy.rb
ee/app/policies/ee/project_policy.rb
+1
-1
ee/spec/policies/project_policy_spec.rb
ee/spec/policies/project_policy_spec.rb
+11
-0
No files found.
ee/app/policies/ee/project_policy.rb
View file @
89880745
...
...
@@ -82,7 +82,7 @@ module EE
with_scope
:subject
condition
(
:licenses_list_enabled
)
do
@subject
.
feature_available?
(
:licenses_list
)
@subject
.
beta_
feature_available?
(
:licenses_list
)
end
with_scope
:subject
...
...
ee/spec/policies/project_policy_spec.rb
View file @
89880745
...
...
@@ -851,6 +851,17 @@ describe ProjectPolicy do
end
end
context
"when the licenses_list feature is enabled for a specific project"
do
let
(
:current_user
)
{
create
(
:user
)
}
before
do
stub_feature_flags
(
licenses_list:
{
enabled:
true
,
thing:
project
})
stub_licensed_features
(
license_management:
true
)
end
it
{
is_expected
.
to
be_allowed
(
:read_licenses_list
)
}
end
context
'when license management feature in not available'
do
let
(
:current_user
)
{
admin
}
...
...
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