Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/lib/gitlab/sherlock/transaction_spec.rb')
-rw-r--r--spec/lib/gitlab/sherlock/transaction_spec.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/spec/lib/gitlab/sherlock/transaction_spec.rb b/spec/lib/gitlab/sherlock/transaction_spec.rb
index 2245c3ee8e2..728c44df4f3 100644
--- a/spec/lib/gitlab/sherlock/transaction_spec.rb
+++ b/spec/lib/gitlab/sherlock/transaction_spec.rb
@@ -167,8 +167,9 @@ describe Gitlab::Sherlock::Transaction do
allow(Gitlab::Sherlock).to receive(:enable_line_profiler?)
.and_return(true)
- allow_any_instance_of(Gitlab::Sherlock::LineProfiler)
- .to receive(:profile).and_return('cats are amazing', [])
+ allow_next_instance_of(Gitlab::Sherlock::LineProfiler) do |instance|
+ allow(instance).to receive(:profile).and_return('cats are amazing', [])
+ end
retval = transaction.profile_lines { 'cats are amazing' }