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
3a8f4a34
Commit
3a8f4a34
authored
Aug 03, 2017
by
Jacob Vosmaer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unnecessary 'raw' alias
parent
29a07fd3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
7 deletions
+1
-7
lib/gitlab/git/repository.rb
lib/gitlab/git/repository.rb
+0
-5
spec/lib/gitlab/git/commit_spec.rb
spec/lib/gitlab/git/commit_spec.rb
+1
-1
spec/lib/gitlab/git/repository_spec.rb
spec/lib/gitlab/git/repository_spec.rb
+0
-1
No files found.
lib/gitlab/git/repository.rb
View file @
3a8f4a34
...
@@ -58,11 +58,6 @@ module Gitlab
...
@@ -58,11 +58,6 @@ module Gitlab
end
end
end
end
# Alias to old method for compatibility
def
raw
rugged
end
def
rugged
def
rugged
@rugged
||=
Rugged
::
Repository
.
new
(
path
,
alternates:
alternate_object_directories
)
@rugged
||=
Rugged
::
Repository
.
new
(
path
,
alternates:
alternate_object_directories
)
rescue
Rugged
::
RepositoryError
,
Rugged
::
OSError
rescue
Rugged
::
RepositoryError
,
Rugged
::
OSError
...
...
spec/lib/gitlab/git/commit_spec.rb
View file @
3a8f4a34
...
@@ -114,7 +114,7 @@ describe Gitlab::Git::Commit, seed_helper: true do
...
@@ -114,7 +114,7 @@ describe Gitlab::Git::Commit, seed_helper: true do
describe
'.find'
do
describe
'.find'
do
it
"should return first head commit if without params"
do
it
"should return first head commit if without params"
do
expect
(
Gitlab
::
Git
::
Commit
.
last
(
repository
).
id
).
to
eq
(
expect
(
Gitlab
::
Git
::
Commit
.
last
(
repository
).
id
).
to
eq
(
repository
.
r
aw
.
head
.
target
.
oid
repository
.
r
ugged
.
head
.
target
.
oid
)
)
end
end
...
...
spec/lib/gitlab/git/repository_spec.rb
View file @
3a8f4a34
...
@@ -22,7 +22,6 @@ describe Gitlab::Git::Repository, seed_helper: true do
...
@@ -22,7 +22,6 @@ describe Gitlab::Git::Repository, seed_helper: true do
describe
"Respond to"
do
describe
"Respond to"
do
subject
{
repository
}
subject
{
repository
}
it
{
is_expected
.
to
respond_to
(
:raw
)
}
it
{
is_expected
.
to
respond_to
(
:rugged
)
}
it
{
is_expected
.
to
respond_to
(
:rugged
)
}
it
{
is_expected
.
to
respond_to
(
:root_ref
)
}
it
{
is_expected
.
to
respond_to
(
:root_ref
)
}
it
{
is_expected
.
to
respond_to
(
:tags
)
}
it
{
is_expected
.
to
respond_to
(
:tags
)
}
...
...
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