BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
127a986d
Commit
127a986d
authored
Aug 23, 2017
by
Stan Hu
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into sh-headless-chrome-support
parents
3e4b7e98
539ed0a6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
commit_service.rb
lib/gitlab/gitaly_client/commit_service.rb
+2
-2
commit_service_spec.rb
spec/lib/gitlab/gitaly_client/commit_service_spec.rb
+14
-0
No files found.
lib/gitlab/gitaly_client/commit_service.rb
View file @
127a986d
...
...
@@ -80,8 +80,8 @@ module Gitlab
def
tree_entries
(
repository
,
revision
,
path
)
request
=
Gitaly
::
GetTreeEntriesRequest
.
new
(
repository:
@gitaly_repo
,
revision:
revision
,
path:
path
.
presen
ce
||
'.'
revision:
GitalyClient
.
encode
(
revision
)
,
path:
path
.
presen
t?
?
GitalyClient
.
encode
(
path
)
:
'.'
)
response
=
GitalyClient
.
call
(
@repository
.
storage
,
:commit_service
,
:get_tree_entries
,
request
)
...
...
spec/lib/gitlab/gitaly_client/commit_service_spec.rb
View file @
127a986d
...
...
@@ -111,6 +111,20 @@ describe Gitlab::GitalyClient::CommitService do
client
.
tree_entries
(
repository
,
revision
,
path
)
end
context
'with UTF-8 params strings'
do
let
(
:revision
)
{
"branch
\u
011F"
}
let
(
:path
)
{
"foo/
\u
011F.txt"
}
it
'handles string encodings correctly'
do
expect_any_instance_of
(
Gitaly
::
CommitService
::
Stub
)
.
to
receive
(
:get_tree_entries
)
.
with
(
gitaly_request_with_path
(
storage_name
,
relative_path
),
kind_of
(
Hash
))
.
and_return
([])
client
.
tree_entries
(
repository
,
revision
,
path
)
end
end
end
describe
'#find_commit'
do
...
...
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