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
e31cf877
Commit
e31cf877
authored
Jul 02, 2020
by
Rémy Coutable
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Try to fix a flaky Epic show spec
Signed-off-by:
Rémy Coutable
<
remy@rymai.me
>
parent
9f929bc4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
8 deletions
+4
-8
ee/spec/features/epics/epic_show_spec.rb
ee/spec/features/epics/epic_show_spec.rb
+4
-8
No files found.
ee/spec/features/epics/epic_show_spec.rb
View file @
e31cf877
...
@@ -141,14 +141,12 @@ RSpec.describe 'Epic show', :js do
...
@@ -141,14 +141,12 @@ RSpec.describe 'Epic show', :js do
let!
(
:notes
)
{
create_list
(
:note
,
2
,
noteable:
epic
)
}
let!
(
:notes
)
{
create_list
(
:note
,
2
,
noteable:
epic
)
}
context
'when sorted by `Oldest first`'
do
context
'when sorted by `Oldest first`'
do
it
'shows
label `Oldest first`
'
do
it
'shows
comments in the correct order
'
do
page
.
within
(
'[data-testid="sort-discussion-filter"]'
)
do
page
.
within
(
'[data-testid="sort-discussion-filter"]'
)
do
expect
(
find
(
'.js-dropdown-text'
)).
to
have_content
(
'Oldest first'
)
expect
(
find
(
'.js-dropdown-text'
)).
to
have_content
(
'Oldest first'
)
end
end
end
it
'shows comments in the correct order'
do
items
=
all
(
'.timeline-entry .timeline-discussion-body .note-text'
)
items
=
all
(
'.timeline-entry .timeline-discussion-body p'
)
expect
(
items
[
0
]).
to
have_content
(
notes
[
0
].
note
)
expect
(
items
[
0
]).
to
have_content
(
notes
[
0
].
note
)
expect
(
items
[
1
]).
to
have_content
(
notes
[
1
].
note
)
expect
(
items
[
1
]).
to
have_content
(
notes
[
1
].
note
)
end
end
...
@@ -163,14 +161,12 @@ RSpec.describe 'Epic show', :js do
...
@@ -163,14 +161,12 @@ RSpec.describe 'Epic show', :js do
end
end
end
end
it
'shows
label `Newest first`
'
do
it
'shows
comments in the correct order
'
do
page
.
within
(
'[data-testid="sort-discussion-filter"]'
)
do
page
.
within
(
'[data-testid="sort-discussion-filter"]'
)
do
expect
(
find
(
'.js-dropdown-text'
)).
to
have_content
(
'Newest first'
)
expect
(
find
(
'.js-dropdown-text'
)).
to
have_content
(
'Newest first'
)
end
end
end
it
'shows comments in the correct order'
do
items
=
all
(
'.timeline-entry .timeline-discussion-body .note-text'
)
items
=
all
(
'.timeline-entry .timeline-discussion-body p'
)
expect
(
items
[
0
]).
to
have_content
(
notes
[
1
].
note
)
expect
(
items
[
0
]).
to
have_content
(
notes
[
1
].
note
)
expect
(
items
[
1
]).
to
have_content
(
notes
[
0
].
note
)
expect
(
items
[
1
]).
to
have_content
(
notes
[
0
].
note
)
end
end
...
...
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