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
9d8aea25
Commit
9d8aea25
authored
Mar 30, 2021
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a unit test checking builds queuing histograms
parent
ea5eb482
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletion
+13
-1
spec/services/ci/register_job_service_spec.rb
spec/services/ci/register_job_service_spec.rb
+13
-1
No files found.
spec/services/ci/register_job_service_spec.rb
View file @
9d8aea25
...
...
@@ -615,13 +615,25 @@ module Ci
create
(
:ci_build
,
pipeline:
pipeline
,
tag_list:
%w[non-matching]
)
end
it
"observes queue size of only matching jobs"
do
it
'observes queue size of only matching jobs'
do
# pending_job + 2 x matching ones
expect
(
Gitlab
::
Ci
::
Queue
::
Metrics
.
queue_size_total
).
to
receive
(
:observe
)
.
with
({
runner_type:
specific_runner
.
runner_type
},
3
)
expect
(
execute
(
specific_runner
)).
to
eq
(
pending_job
)
end
it
'observes queue processing time by the runner type'
do
expect
(
Gitlab
::
Ci
::
Queue
::
Metrics
.
queue_iteration_duration_seconds
)
.
to
receive
(
:observe
)
.
with
({
runner_type:
specific_runner
.
runner_type
},
anything
)
expect
(
Gitlab
::
Ci
::
Queue
::
Metrics
.
queue_retrieval_duration_seconds
)
.
to
receive
(
:observe
)
.
with
({
runner_type:
specific_runner
.
runner_type
},
anything
)
expect
(
execute
(
specific_runner
)).
to
eq
(
pending_job
)
end
end
context
'when ci_register_job_temporary_lock is enabled'
do
...
...
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