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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
90e802cd
Commit
90e802cd
authored
Mar 27, 2017
by
Robert Speicher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use `:empty_project` where possible in policy specs
parent
d281835a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
spec/policies/issue_policy_spec.rb
spec/policies/issue_policy_spec.rb
+1
-1
spec/policies/project_policy_spec.rb
spec/policies/project_policy_spec.rb
+1
-1
No files found.
spec/policies/issue_policy_spec.rb
View file @
90e802cd
...
...
@@ -5,7 +5,7 @@ describe IssuePolicy, models: true do
describe
'#rules'
do
context
'using a regular issue'
do
let
(
:project
)
{
create
(
:project
,
:public
)
}
let
(
:project
)
{
create
(
:
empty_
project
,
:public
)
}
let
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
let
(
:policies
)
{
described_class
.
abilities
(
user
,
issue
).
to_set
}
...
...
spec/policies/project_policy_spec.rb
View file @
90e802cd
...
...
@@ -74,7 +74,7 @@ describe ProjectPolicy, models: true do
end
it
'does not include the read_issue permission when the issue author is not a member of the private project'
do
project
=
create
(
:project
,
:private
)
project
=
create
(
:
empty_
project
,
:private
)
issue
=
create
(
:issue
,
project:
project
)
user
=
issue
.
author
...
...
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