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
Boxiang Sun
gitlab-ce
Commits
a998710a
Commit
a998710a
authored
Apr 26, 2017
by
Kim "BKC" Carlbäcker
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix RSpec
parent
6f89bd36
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
13 deletions
+1
-13
spec/lib/gitlab/git/repository_spec.rb
spec/lib/gitlab/git/repository_spec.rb
+1
-13
No files found.
spec/lib/gitlab/git/repository_spec.rb
View file @
a998710a
...
...
@@ -1074,20 +1074,8 @@ describe Gitlab::Git::Repository, seed_helper: true do
end
describe
'#branch_count'
do
before
(
:each
)
do
valid_ref
=
double
(
:ref
)
invalid_ref
=
double
(
:ref
)
allow
(
valid_ref
).
to
receive_messages
(
name:
'master'
,
target:
double
(
:target
))
allow
(
invalid_ref
).
to
receive_messages
(
name:
'bad-branch'
)
allow
(
invalid_ref
).
to
receive
(
:target
)
{
raise
Rugged
::
ReferenceError
}
allow
(
repository
.
rugged
).
to
receive_messages
(
branches:
[
valid_ref
,
invalid_ref
])
end
it
'returns the number of branches'
do
expect
(
repository
.
branch_count
).
to
eq
(
1
)
expect
(
repository
.
branch_count
).
to
eq
(
9
)
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