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
21eb12d0
Commit
21eb12d0
authored
Aug 26, 2020
by
Sean Arnold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update spec to test data correctly
parent
a0071857
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
spec/requests/api/graphql/project/issues_spec.rb
spec/requests/api/graphql/project/issues_spec.rb
+7
-4
No files found.
spec/requests/api/graphql/project/issues_spec.rb
View file @
21eb12d0
...
...
@@ -261,7 +261,7 @@ RSpec.describe 'getting an issue list for a project' do
<<~
QUERY
edges {
node {
id
i
i
d
alertManagementAlert {
title
}
...
...
@@ -270,9 +270,9 @@ RSpec.describe 'getting an issue list for a project' do
QUERY
end
# Alerts need to
reporter
and above
# Alerts need to
have developer permission
and above
before
do
project
.
add_
report
er
(
current_user
)
project
.
add_
develop
er
(
current_user
)
end
it
'avoids N+1 queries'
do
...
...
@@ -286,7 +286,10 @@ RSpec.describe 'getting an issue list for a project' do
it
'returns the alert data'
do
post_graphql
(
query
,
current_user:
current_user
)
issues_data
alert_titles
=
issues_data
.
map
{
|
issue
|
issue
.
dig
(
'node'
,
'alertManagementAlert'
,
'title'
)
}
expected_titles
=
issues
.
map
{
|
issue
|
issue
.
alert_management_alert
&
.
title
}
expect
(
alert_titles
).
to
contain_exactly
(
*
expected_titles
)
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