summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--spec/support/gitaly.rb7
1 files changed, 5 insertions, 2 deletions
diff --git a/spec/support/gitaly.rb b/spec/support/gitaly.rb
index 89fb362cf14..929a66628ca 100644
--- a/spec/support/gitaly.rb
+++ b/spec/support/gitaly.rb
@@ -1,6 +1,9 @@
RSpec.configure do |config|
config.before(:each) do |example|
- next if example.metadata[:skip_gitaly_mock]
- allow(Gitlab::GitalyClient).to receive(:feature_enabled?).and_return(true)
+ if example.metadata[:skip_gitaly_mock]
+ allow(Gitlab::GitalyClient).to receive(:feature_enabled?).and_return(false)
+ else
+ allow(Gitlab::GitalyClient).to receive(:feature_enabled?).and_return(true)
+ end
end
end