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
1b6debae
Commit
1b6debae
authored
May 19, 2020
by
George Tsiolis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove duplicate test
parent
217e42d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
36 deletions
+0
-36
spec/controllers/projects/pipelines_controller_spec.rb
spec/controllers/projects/pipelines_controller_spec.rb
+0
-36
No files found.
spec/controllers/projects/pipelines_controller_spec.rb
View file @
1b6debae
...
...
@@ -62,42 +62,6 @@ describe Projects::PipelinesController do
end
end
context
'when using legacy stages'
,
:request_store
do
it
'returns JSON with serialized pipelines'
do
get_pipelines_index_json
expect
(
response
).
to
have_gitlab_http_status
(
:ok
)
expect
(
response
).
to
match_response_schema
(
'pipeline'
)
expect
(
json_response
).
to
include
(
'pipelines'
)
expect
(
json_response
[
'pipelines'
].
count
).
to
eq
6
expect
(
json_response
[
'count'
][
'all'
]).
to
eq
'6'
expect
(
json_response
[
'count'
][
'running'
]).
to
eq
'2'
expect
(
json_response
[
'count'
][
'pending'
]).
to
eq
'1'
expect
(
json_response
[
'count'
][
'finished'
]).
to
eq
'3'
json_response
.
dig
(
'pipelines'
,
0
,
'details'
,
'stages'
).
tap
do
|
stages
|
expect
(
stages
.
count
).
to
eq
3
end
end
it
'does not execute N+1 queries'
do
get_pipelines_index_json
control_count
=
ActiveRecord
::
QueryRecorder
.
new
do
get_pipelines_index_json
end
.
count
create_all_pipeline_types
# There appears to be one extra query for Pipelines#has_warnings? for some reason
expect
{
get_pipelines_index_json
}.
not_to
exceed_query_limit
(
control_count
+
1
)
expect
(
response
).
to
have_gitlab_http_status
(
:ok
)
expect
(
json_response
[
'pipelines'
].
count
).
to
eq
12
end
end
it
'does not include coverage data for the pipelines'
do
get_pipelines_index_json
...
...
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