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
Jérome Perrin
gitlab-ce
Commits
ea448039
Commit
ea448039
authored
Aug 10, 2017
by
Filipa Lacerda
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix broken tests
parent
57f52b9e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
29 additions
and
5 deletions
+29
-5
app/assets/javascripts/notes/components/issue_comment_form.vue
...ssets/javascripts/notes/components/issue_comment_form.vue
+2
-2
features/steps/shared/note.rb
features/steps/shared/note.rb
+5
-2
spec/javascripts/notes/components/issue_discussion_spec.js
spec/javascripts/notes/components/issue_discussion_spec.js
+21
-0
spec/javascripts/zen_mode_spec.js
spec/javascripts/zen_mode_spec.js
+1
-1
No files found.
app/assets/javascripts/notes/components/issue_comment_form.vue
View file @
ea448039
...
...
@@ -43,7 +43,7 @@
'
getNotesData
'
,
]),
isLoggedIn
()
{
return
this
.
getUserData
!==
null
;
return
this
.
getUserData
.
id
;
},
commentButtonTitle
()
{
return
this
.
noteType
===
constants
.
COMMENT
?
'
Comment
'
:
'
Start discussion
'
;
...
...
@@ -92,7 +92,7 @@
'
saveNote
'
,
]),
setIsSubmitButtonDisabled
(
note
,
isSubmitting
)
{
if
(
!
_
.
isEmpty
(
note
)
&&
!
isSubmitting
)
{
if
(
!
_
.
isEmpty
(
note
)
&&
!
isSubmitting
)
{
this
.
isSubmitButtonDisabled
=
false
;
}
else
{
this
.
isSubmitButtonDisabled
=
true
;
...
...
features/steps/shared/note.rb
View file @
ea448039
...
...
@@ -137,7 +137,7 @@ module SharedNote
step
'The comment with the header should not have an ID'
do
page
.
within
(
".note-body > .note-text"
)
do
expect
(
page
).
to
have_content
(
"Comment with a header"
)
expect
(
page
).
to
have_content
(
"Comment with a header"
)
expect
(
page
).
not_to
have_css
(
"#comment-with-a-header"
)
end
end
...
...
@@ -153,10 +153,13 @@ module SharedNote
note
.
find
(
'.js-note-edit'
).
click
end
page
.
find
(
'.current-note-edit-form textarea'
)
page
.
within
(
".current-note-edit-form"
)
do
fill_in
'
note[note]
'
,
with:
'+1 Awesome!'
fill_in
'
#note-body
'
,
with:
'+1 Awesome!'
click_button
'Save comment'
end
wait_for_requests
end
step
'I should see +1 in the description'
do
...
...
spec/javascripts/notes/components/issue_discussion_spec.js
View file @
ea448039
import
Vue
from
'
vue
'
;
import
store
from
'
~/notes/stores
'
;
import
issueDiscussion
from
'
~/notes/components/issue_discussion.vue
'
;
import
{
issueDataMock
,
discussionMock
}
from
'
../mock_data
'
;
describe
(
'
issue_discussion component
'
,
()
=>
{
let
vm
;
beforeEach
(()
=>
{
const
Component
=
Vue
.
extend
(
issueDiscussion
);
store
.
dispatch
(
'
setIssueData
'
,
issueDataMock
);
vm
=
new
Component
({
store
,
propsData
:
{
note
:
discussionMock
,
},
}).
$mount
();
});
it
(
'
should render user avatar
'
,
()
=>
{
console
.
log
(
'
vm
'
,
vm
.
$el
);
});
...
...
spec/javascripts/zen_mode_spec.js
View file @
ea448039
...
...
@@ -8,7 +8,7 @@ import ZenMode from '~/zen_mode';
var
enterZen
,
escapeKeydown
,
exitZen
;
describe
(
'
ZenMode
'
,
function
()
{
var
fixtureName
=
'
issues/open-issue
.html.raw
'
;
var
fixtureName
=
'
merge_requests/merge_request_with_comment
.html.raw
'
;
preloadFixtures
(
fixtureName
);
beforeEach
(
function
()
{
loadFixtures
(
fixtureName
);
...
...
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