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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
ce22977f
Commit
ce22977f
authored
Nov 01, 2017
by
Luke "Jared" Bennett
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use settimeoutpromise in field_spec
parent
af13ffbc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
23 deletions
+14
-23
spec/javascripts/vue_shared/components/markdown/field_spec.js
.../javascripts/vue_shared/components/markdown/field_spec.js
+14
-23
No files found.
spec/javascripts/vue_shared/components/markdown/field_spec.js
View file @
ce22977f
import
Vue
from
'
vue
'
;
import
Vue
from
'
vue
'
;
import
fieldComponent
from
'
~/vue_shared/components/markdown/field.vue
'
;
import
fieldComponent
from
'
~/vue_shared/components/markdown/field.vue
'
;
import
setTimeoutPromise
from
'
../../../helpers/set_timeout_promise_helper
'
;
describe
(
'
Markdown field component
'
,
()
=>
{
describe
(
'
Markdown field component
'
,
()
=>
{
let
vm
;
let
vm
;
...
@@ -115,29 +116,19 @@ describe('Markdown field component', () => {
...
@@ -115,29 +116,19 @@ describe('Markdown field component', () => {
it
(
'
clicking already active write or preview link does nothing
'
,
(
done
)
=>
{
it
(
'
clicking already active write or preview link does nothing
'
,
(
done
)
=>
{
writeLink
.
click
();
writeLink
.
click
();
setTimeout
(()
=>
{
setTimeoutPromise
()
assertLinks
(
true
);
.
then
(()
=>
assertLinks
(
true
))
.
then
(()
=>
writeLink
.
click
())
writeLink
.
click
();
.
then
(()
=>
setTimeoutPromise
())
.
then
(()
=>
assertLinks
(
true
))
setTimeout
(()
=>
{
.
then
(()
=>
previewLink
.
click
())
assertLinks
(
true
);
.
then
(()
=>
setTimeoutPromise
())
.
then
(()
=>
assertLinks
(
false
))
previewLink
.
click
();
.
then
(()
=>
previewLink
.
click
())
.
then
(()
=>
setTimeoutPromise
())
setTimeout
(()
=>
{
.
then
(()
=>
assertLinks
(
false
))
assertLinks
(
false
);
.
then
(
done
)
.
catch
(
done
.
fail
);
previewLink
.
click
();
setTimeout
(()
=>
{
assertLinks
(
false
);
done
();
});
});
});
});
});
});
});
});
...
...
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