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
e917f90f
Commit
e917f90f
authored
Feb 09, 2021
by
Jose Vargas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add GlIcon expectation to tests
parent
afd941e8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
spec/frontend/vue_shared/components/ci_icon_spec.js
spec/frontend/vue_shared/components/ci_icon_spec.js
+5
-4
No files found.
spec/frontend/vue_shared/components/ci_icon_spec.js
View file @
e917f90f
import
{
mount
}
from
'
@vue/test-utils
'
;
import
{
shallowMount
}
from
'
@vue/test-utils
'
;
import
{
GlIcon
}
from
'
@gitlab/ui
'
;
import
ciIcon
from
'
~/vue_shared/components/ci_icon.vue
'
;
describe
(
'
CI Icon component
'
,
()
=>
{
...
...
@@ -10,7 +11,7 @@ describe('CI Icon component', () => {
});
it
(
'
should render a span element with an svg
'
,
()
=>
{
wrapper
=
m
ount
(
ciIcon
,
{
wrapper
=
shallowM
ount
(
ciIcon
,
{
propsData
:
{
status
:
{
icon
:
'
status_success
'
,
...
...
@@ -19,7 +20,7 @@ describe('CI Icon component', () => {
});
expect
(
wrapper
.
find
(
'
span
'
).
exists
()).
toBe
(
true
);
expect
(
wrapper
.
find
(
'
span > svg
'
).
exists
()).
toBe
(
true
);
expect
(
wrapper
.
find
(
GlIcon
).
exists
()).
toBe
(
true
);
});
describe
(
'
rendering a status
'
,
()
=>
{
...
...
@@ -35,7 +36,7 @@ describe('CI Icon component', () => {
${
'
status_canceled
'
}
|
${
'
canceled
'
}
|
${
'
ci-status-icon-canceled
'
}
${
'
status_manual
'
}
|
${
'
manual
'
}
|
${
'
ci-status-icon-manual
'
}
`
(
'
should render a $group status
'
,
({
icon
,
group
,
cssClass
})
=>
{
wrapper
=
m
ount
(
ciIcon
,
{
wrapper
=
shallowM
ount
(
ciIcon
,
{
propsData
:
{
status
:
{
icon
,
...
...
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