diff options
Diffstat (limited to 'spec/support/helpers/stub_gitlab_calls.rb')
-rw-r--r-- | spec/support/helpers/stub_gitlab_calls.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/support/helpers/stub_gitlab_calls.rb b/spec/support/helpers/stub_gitlab_calls.rb index 748ea525e40..6d0e97b0a75 100644 --- a/spec/support/helpers/stub_gitlab_calls.rb +++ b/spec/support/helpers/stub_gitlab_calls.rb @@ -23,6 +23,10 @@ module StubGitlabCalls end def stub_ci_pipeline_yaml_file(ci_yaml_content) + allow_any_instance_of(Gitlab::Ci::ProjectConfig::Repository) + .to receive(:file_in_repository?) + .and_return(ci_yaml_content.present?) + allow_any_instance_of(Repository) .to receive(:gitlab_ci_yml_for) .and_return(ci_yaml_content) |