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
38a08da5
Commit
38a08da5
authored
Jun 06, 2020
by
Himanshu Kapoor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Migrate ee/issuable specs to Jest
Migrate specs in ee/spec/javascripts/issuable to Jest
parent
16d431fc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
ee/spec/frontend/issuable/related_issues/components/add_issuable_form_spec.js
...uable/related_issues/components/add_issuable_form_spec.js
+8
-3
No files found.
ee/spec/
javascripts
/issuable/related_issues/components/add_issuable_form_spec.js
→
ee/spec/
frontend
/issuable/related_issues/components/add_issuable_form_spec.js
View file @
38a08da5
...
...
@@ -36,6 +36,11 @@ describe('AddIssuableForm', () => {
let
wrapper
;
afterEach
(()
=>
{
// Jest doesn't blur an item even if it is destroyed,
// so blur the input manually after each test
const
input
=
findFormInput
(
wrapper
);
if
(
input
)
input
.
blur
();
wrapper
.
destroy
();
});
...
...
@@ -178,7 +183,7 @@ describe('AddIssuableForm', () => {
describe
(
'
when the form is submitted
'
,
()
=>
{
it
(
'
emits an event with a "relates_to" link type when the "relates to" radio input selected
'
,
done
=>
{
spyOn
(
wrapper
.
vm
,
'
$emit
'
);
jest
.
spyOn
(
wrapper
.
vm
,
'
$emit
'
).
mockImplementation
(()
=>
{}
);
wrapper
.
vm
.
linkedIssueType
=
linkedIssueTypesMap
.
RELATES_TO
;
wrapper
.
vm
.
onFormSubmit
();
...
...
@@ -193,7 +198,7 @@ describe('AddIssuableForm', () => {
});
it
(
'
emits an event with a "blocks" link type when the "blocks" radio input selected
'
,
done
=>
{
spyOn
(
wrapper
.
vm
,
'
$emit
'
);
jest
.
spyOn
(
wrapper
.
vm
,
'
$emit
'
).
mockImplementation
(()
=>
{}
);
wrapper
.
vm
.
linkedIssueType
=
linkedIssueTypesMap
.
BLOCKS
;
wrapper
.
vm
.
onFormSubmit
();
...
...
@@ -208,7 +213,7 @@ describe('AddIssuableForm', () => {
});
it
(
'
emits an event with a "is_blocked_by" link type when the "is blocked by" radio input selected
'
,
done
=>
{
spyOn
(
wrapper
.
vm
,
'
$emit
'
);
jest
.
spyOn
(
wrapper
.
vm
,
'
$emit
'
).
mockImplementation
(()
=>
{}
);
wrapper
.
vm
.
linkedIssueType
=
linkedIssueTypesMap
.
IS_BLOCKED_BY
;
wrapper
.
vm
.
onFormSubmit
();
...
...
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