Unable to merge requests with merge only when pipeline succeeds option enabled but without gitlab-ci file

Summary

Cannot merge a merge request if Pipelines must succeed enabled in the merge checks of a project without pipeline.

Usually we enable a couple of default settings that we want to have across all the projects and this is one of them, but while the projects doesn't have a pipeline, we can't merge the requests, we have to disable the setting.

Steps to reproduce

In a project without pipelines

  1. Go to the project settings, to the merge requests section and in the merge checks enable the Pipelines must succeed option
  2. Create a new merge request without a gitlab-ci file
  3. You should see the Merge button disabled with the message You can only merge once the items above are resolved

What is the current bug behavior?

Unable to merge the merge request

What is the expected correct behavior?

Do not allow the option to be enabled OR allow the merge request to be merged even without pipelines.

Relevant logs and/or screenshots

Screenshot_2019-07-10_at_14.44.22

Screenshot_2019-07-10_at_14.44.32

@filipa please let me know if you need anything else 😉