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
8b931547
Commit
8b931547
authored
Sep 26, 2019
by
Thomas Randolph
Committed by
Igor Drozdov
Oct 03, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update last commit tests and snapshots
Also translates some bare text and removes a linter override
parent
048c1130
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
115 additions
and
2 deletions
+115
-2
app/assets/javascripts/repository/components/last_commit.vue
app/assets/javascripts/repository/components/last_commit.vue
+1
-2
locale/gitlab.pot
locale/gitlab.pot
+3
-0
spec/frontend/repository/components/__snapshots__/last_commit_spec.js.snap
...ository/components/__snapshots__/last_commit_spec.js.snap
+105
-0
spec/frontend/repository/components/last_commit_spec.js
spec/frontend/repository/components/last_commit_spec.js
+6
-0
No files found.
app/assets/javascripts/repository/components/last_commit.vue
View file @
8b931547
<
script
>
/* eslint-disable @gitlab/vue-i18n/no-bare-strings */
import
{
GlTooltipDirective
,
GlLink
,
GlButton
,
GlLoadingIcon
}
from
'
@gitlab/ui
'
;
import
{
sprintf
,
s__
}
from
'
~/locale
'
;
import
Icon
from
'
../../vue_shared/components/icon.vue
'
;
...
...
@@ -113,7 +112,7 @@ export default {
>
{{
commit
.
author
.
name
}}
</gl-link>
authored
{{
s__
(
'
LastCommit|authored
'
)
}}
<timeago-tooltip
:time=
"commit.authoredDate"
tooltip-placement=
"bottom"
/>
</div>
<pre
...
...
locale/gitlab.pot
View file @
8b931547
...
...
@@ -9227,6 +9227,9 @@ msgstr ""
msgid "Last used on:"
msgstr ""
msgid "LastCommit|authored"
msgstr ""
msgid "LastPushEvent|You pushed to"
msgstr ""
...
...
spec/frontend/repository/components/__snapshots__/last_commit_spec.js.snap
View file @
8b931547
...
...
@@ -60,6 +60,111 @@ exports[`Repository last commit component renders commit widget 1`] = `
<div
class="commit-actions flex-row"
>
<!---->
<gllink-stub
class="js-commit-pipeline"
data-original-title="Commit: failed"
href="https://test.com/pipeline"
title=""
>
<ciicon-stub
aria-label="Commit: failed"
cssclasses=""
size="24"
status="[object Object]"
/>
</gllink-stub>
<div
class="commit-sha-group d-flex"
>
<div
class="label label-monospace monospace"
>
12345678
</div>
<clipboardbutton-stub
cssclass="btn-default"
text="123456789"
title="Copy commit SHA to clipboard"
tooltipplacement="bottom"
/>
</div>
</div>
</div>
</div>
`;
exports[`Repository last commit component renders the signature HTML as returned by the backend 1`] = `
<div
class="info-well d-none d-sm-flex project-last-commit commit p-3"
>
<useravatarlink-stub
class="avatar-cell"
imgalt=""
imgcssclasses=""
imgsize="40"
imgsrc="https://test.com"
linkhref="https://test.com/test"
tooltipplacement="top"
tooltiptext=""
username=""
/>
<div
class="commit-detail flex-list"
>
<div
class="commit-content qa-commit-content"
>
<gllink-stub
class="commit-row-message item-title"
href="https://test.com/commit/123"
>
Commit title
</gllink-stub>
<!---->
<div
class="committer"
>
<gllink-stub
class="commit-author-link js-user-link"
href="https://test.com/test"
>
Test
</gllink-stub>
authored
<timeagotooltip-stub
cssclass=""
time="2019-01-01"
tooltipplacement="bottom"
/>
</div>
<!---->
</div>
<div
class="commit-actions flex-row"
>
<div>
<button>
Verified
</button>
</div>
<gllink-stub
class="js-commit-pipeline"
data-original-title="Commit: failed"
...
...
spec/frontend/repository/components/last_commit_spec.js
View file @
8b931547
...
...
@@ -107,4 +107,10 @@ describe('Repository last commit component', () => {
expect
(
vm
.
find
(
'
.commit-row-description
'
).
isVisible
()).
toBe
(
true
);
expect
(
vm
.
find
(
'
.text-expander
'
).
classes
(
'
open
'
)).
toBe
(
true
);
});
it
(
'
renders the signature HTML as returned by the backend
'
,
()
=>
{
factory
(
createCommitData
({
signatureHtml
:
'
<button>Verified</button>
'
}));
expect
(
vm
.
element
).
toMatchSnapshot
();
});
});
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