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
e4b61b7c
Commit
e4b61b7c
authored
Oct 12, 2020
by
Natalia Tepluhina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix environment_app spec and pipelines_table spec
parent
bda7a261
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
28 deletions
+2
-28
spec/frontend/environments/environments_app_spec.js
spec/frontend/environments/environments_app_spec.js
+2
-2
spec/frontend/pipelines/pipelines_table_spec.js
spec/frontend/pipelines/pipelines_table_spec.js
+0
-26
No files found.
spec/frontend/environments/environments_app_spec.js
View file @
e4b61b7c
...
...
@@ -182,7 +182,7 @@ describe('Environment', () => {
describe
(
'
when user can create environment
'
,
()
=>
{
beforeEach
(()
=>
{
mockRequest
([
environment
]);
wrapper
=
m
ount
(
EnvironmentsApp
,
{
propsData
:
mockData
});
wrapper
=
shallowM
ount
(
EnvironmentsApp
,
{
propsData
:
mockData
});
});
it
(
'
should render
'
,
()
=>
{
...
...
@@ -193,7 +193,7 @@ describe('Environment', () => {
describe
(
'
when user can not create environment
'
,
()
=>
{
beforeEach
(()
=>
{
mockRequest
([
environment
]);
wrapper
=
m
ount
(
EnvironmentsApp
,
{
wrapper
=
shallowM
ount
(
EnvironmentsApp
,
{
propsData
:
{
...
mockData
,
canCreateEnvironment
:
false
},
});
});
...
...
spec/frontend/pipelines/pipelines_table_spec.js
View file @
e4b61b7c
import
{
GlButton
}
from
'
@gitlab/ui
'
;
import
{
mount
}
from
'
@vue/test-utils
'
;
import
PipelinesTable
from
'
~/pipelines/components/pipelines_list/pipelines_table.vue
'
;
...
...
@@ -20,7 +19,6 @@ describe('Pipelines Table', () => {
});
};
const
findRows
=
()
=>
wrapper
.
findAll
(
'
.commit.gl-responsive-table-row
'
);
const
findGlButtons
=
()
=>
wrapper
.
findAll
(
GlButton
);
preloadFixtures
(
jsonFixtureName
);
...
...
@@ -65,28 +63,4 @@ describe('Pipelines Table', () => {
expect
(
findRows
()).
toHaveLength
(
1
);
});
});
describe
(
'
pipline actions
'
,
()
=>
{
it
(
'
should set the "Re-deploy" title
'
,
()
=>
{
const
pipelines
=
[{
...
pipeline
,
flags
:
{
cancelable
:
false
,
retryable
:
true
}
}];
createComponent
({
...
defaultProps
,
pipelines
});
expect
(
findGlButtons
().
length
).
toBe
(
1
);
expect
(
findGlButtons
()
.
at
(
0
)
.
attributes
(
'
title
'
),
).
toMatch
(
'
Retry
'
);
});
it
(
'
should set the "Cancel" title
'
,
()
=>
{
const
pipelines
=
[{
...
pipeline
,
flags
:
{
cancelable
:
true
,
retryable
:
false
}
}];
createComponent
({
...
defaultProps
,
pipelines
});
expect
(
findGlButtons
().
length
).
toBe
(
1
);
expect
(
findGlButtons
()
.
at
(
0
)
.
attributes
(
'
title
'
),
).
toMatch
(
'
Cancel
'
);
});
});
});
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