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
57508ba7
Commit
57508ba7
authored
Sep 03, 2021
by
Heinrich Lee Yu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clear memoization of a stubbed object
This fixes succeeding specs that call pipeline_creation_step_histogram
parent
662760b9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
spec/lib/gitlab/ci/pipeline/metrics_spec.rb
spec/lib/gitlab/ci/pipeline/metrics_spec.rb
+7
-1
spec/lib/gitlab/ci/templates/Terraform/base_latest_gitlab_ci_yaml_spec.rb
...ci/templates/Terraform/base_latest_gitlab_ci_yaml_spec.rb
+1
-1
No files found.
spec/lib/gitlab/ci/pipeline/metrics_spec.rb
View file @
57508ba7
...
...
@@ -4,9 +4,15 @@ require 'spec_helper'
RSpec
.
describe
::
Gitlab
::
Ci
::
Pipeline
::
Metrics
do
describe
'.pipeline_creation_step_duration_histogram'
do
it
'adds the step to the step duration histogram'
do
around
do
|
example
|
described_class
.
clear_memoization
(
:pipeline_creation_step_histogram
)
example
.
run
described_class
.
clear_memoization
(
:pipeline_creation_step_histogram
)
end
it
'adds the step to the step duration histogram'
do
expect
(
::
Gitlab
::
Metrics
).
to
receive
(
:histogram
)
.
with
(
:gitlab_ci_pipeline_creation_step_duration_seconds
,
...
...
spec/lib/gitlab/ci/templates/Terraform/base_latest_gitlab_ci_yaml_spec.rb
View file @
57508ba7
...
...
@@ -19,7 +19,7 @@ RSpec.describe 'Terraform/Base.latest.gitlab-ci.yml' do
allow
(
project
).
to
receive
(
:default_branch
).
and_return
(
default_branch
)
end
it
'does not create any jobs'
,
quarantine:
'https://gitlab.com/gitlab-org/gitlab/-/issues/339979'
do
it
'does not create any jobs'
do
expect
(
build_names
).
to
be_empty
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