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
6965339d
Commit
6965339d
authored
Dec 21, 2021
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve specs for register job service metrics collector
parent
16bff374
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
2 deletions
+15
-2
spec/services/ci/register_job_service_spec.rb
spec/services/ci/register_job_service_spec.rb
+15
-2
No files found.
spec/services/ci/register_job_service_spec.rb
View file @
6965339d
...
...
@@ -827,8 +827,13 @@ module Ci
end
context
'when project already has running jobs'
do
let!
(
:build2
)
{
create
(
:ci_build
,
:running
,
pipeline:
pipeline
,
runner:
shared_runner
)
}
let!
(
:build3
)
{
create
(
:ci_build
,
:running
,
pipeline:
pipeline
,
runner:
shared_runner
)
}
let
(
:build2
)
{
create
(
:ci_build
,
:running
,
pipeline:
pipeline
,
runner:
shared_runner
)
}
let
(
:build3
)
{
create
(
:ci_build
,
:running
,
pipeline:
pipeline
,
runner:
shared_runner
)
}
before
do
::
Ci
::
RunningBuild
.
upsert_shared_runner_build!
(
build2
)
::
Ci
::
RunningBuild
.
upsert_shared_runner_build!
(
build3
)
end
it
'counts job queuing time histogram with expected labels'
do
allow
(
attempt_counter
).
to
receive
(
:increment
)
...
...
@@ -845,6 +850,14 @@ module Ci
shared_examples
'metrics collector'
do
it_behaves_like
'attempt counter collector'
it_behaves_like
'jobs queueing time histogram collector'
context
'when using denormalized data is disabled'
do
before
do
stub_feature_flags
(
ci_pending_builds_maintain_denormalized_data:
false
)
end
it_behaves_like
'jobs queueing time histogram collector'
end
end
context
'when shared runner is used'
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