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
a3cf3e50
Commit
a3cf3e50
authored
Aug 11, 2017
by
Filipa Lacerda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix broken markdown field test
parent
c7dbba8b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
app/assets/javascripts/vue_shared/components/markdown/field.vue
...sets/javascripts/vue_shared/components/markdown/field.vue
+4
-5
spec/javascripts/vue_shared/components/markdown/field_spec.js
.../javascripts/vue_shared/components/markdown/field_spec.js
+2
-1
No files found.
app/assets/javascripts/vue_shared/components/markdown/field.vue
View file @
a3cf3e50
...
@@ -64,12 +64,11 @@
...
@@ -64,12 +64,11 @@
.
then
(
resp
=>
resp
.
json
())
.
then
(
resp
=>
resp
.
json
())
.
then
((
data
)
=>
{
.
then
((
data
)
=>
{
this
.
markdownPreviewLoading
=
false
;
this
.
markdownPreviewLoading
=
false
;
this
.
markdownPreview
=
data
.
body
;
this
.
markdownPreview
=
data
.
body
||
'
Nothing to preview.
'
;
this
.
referencedCommands
=
data
.
references
.
commands
;
this
.
referencedUsers
=
data
.
references
.
users
;
if
(
!
this
.
markdownPreview
)
{
if
(
data
.
references
)
{
this
.
markdownPreview
=
'
Nothing to preview.
'
;
this
.
referencedCommands
=
data
.
references
.
commands
;
this
.
referencedUsers
=
data
.
references
.
users
;
}
}
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
...
...
spec/javascripts/vue_shared/components/markdown/field_spec.js
View file @
a3cf3e50
...
@@ -92,6 +92,7 @@ describe('Markdown field component', () => {
...
@@ -92,6 +92,7 @@ describe('Markdown field component', () => {
it
(
'
renders GFM with jQuery
'
,
(
done
)
=>
{
it
(
'
renders GFM with jQuery
'
,
(
done
)
=>
{
spyOn
(
$
.
fn
,
'
renderGFM
'
);
spyOn
(
$
.
fn
,
'
renderGFM
'
);
previewLink
.
click
();
previewLink
.
click
();
setTimeout
(()
=>
{
setTimeout
(()
=>
{
...
@@ -100,7 +101,7 @@ describe('Markdown field component', () => {
...
@@ -100,7 +101,7 @@ describe('Markdown field component', () => {
).
toHaveBeenCalled
();
).
toHaveBeenCalled
();
done
();
done
();
});
}
,
0
);
});
});
});
});
...
...
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