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
c5458ddf
Commit
c5458ddf
authored
Oct 06, 2020
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Ruby 2.7 warnings in spec/support/helpers/cycle_analytics_helpers.rb
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
ad138e9c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
spec/support/helpers/cycle_analytics_helpers.rb
spec/support/helpers/cycle_analytics_helpers.rb
+3
-5
No files found.
spec/support/helpers/cycle_analytics_helpers.rb
View file @
c5458ddf
...
@@ -126,17 +126,15 @@ module CycleAnalyticsHelpers
...
@@ -126,17 +126,15 @@ module CycleAnalyticsHelpers
end
end
def
mock_gitaly_multi_action_dates
(
repository
,
commit_time
)
def
mock_gitaly_multi_action_dates
(
repository
,
commit_time
)
allow
(
repository
.
raw
).
to
receive
(
:multi_action
).
and_wrap_original
do
|
m
,
*
args
|
allow
(
repository
.
raw
).
to
receive
(
:multi_action
).
and_wrap_original
do
|
m
,
user
,
k
args
|
new_date
=
commit_time
||
Time
.
now
new_date
=
commit_time
||
Time
.
now
branch_update
=
m
.
call
(
*
args
)
branch_update
=
m
.
call
(
user
,
**
k
args
)
if
branch_update
.
newrev
if
branch_update
.
newrev
_
,
opts
=
args
commit
=
rugged_repo
(
repository
).
rev_parse
(
branch_update
.
newrev
)
commit
=
rugged_repo
(
repository
).
rev_parse
(
branch_update
.
newrev
)
branch_update
.
newrev
=
commit
.
amend
(
branch_update
.
newrev
=
commit
.
amend
(
update_ref:
"
#{
Gitlab
::
Git
::
BRANCH_REF_PREFIX
}#{
opt
s
[
:branch_name
]
}
"
,
update_ref:
"
#{
Gitlab
::
Git
::
BRANCH_REF_PREFIX
}#{
karg
s
[
:branch_name
]
}
"
,
author:
commit
.
author
.
merge
(
time:
new_date
),
author:
commit
.
author
.
merge
(
time:
new_date
),
committer:
commit
.
committer
.
merge
(
time:
new_date
)
committer:
commit
.
committer
.
merge
(
time:
new_date
)
)
)
...
...
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