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
f1d3a92b
Commit
f1d3a92b
authored
Mar 02, 2017
by
http://jneen.net/
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
spec the behavior of nil subjects
parent
a5c05544
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
spec/models/ability_spec.rb
spec/models/ability_spec.rb
+6
-0
No files found.
spec/models/ability_spec.rb
View file @
f1d3a92b
require
'spec_helper'
describe
Ability
,
lib:
true
do
context
'using a nil subject'
do
it
'is always empty'
do
expect
(
Ability
.
allowed
(
nil
,
nil
).
to_set
).
to
be_empty
end
end
describe
'.can_edit_note?'
do
let
(
:project
)
{
create
(
:empty_project
)
}
let
(
:note
)
{
create
(
:note_on_issue
,
project:
project
)
}
...
...
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