diff options
author | Kamil Trzciński <ayufan@ayufan.eu> | 2018-12-04 15:32:47 +0300 |
---|---|---|
committer | Kamil Trzciński <ayufan@ayufan.eu> | 2018-12-04 15:32:47 +0300 |
commit | 77f215b3f4feaab49f9d10975554b8c866e865f9 (patch) | |
tree | 1a67fc6cf96a638b57b500de38ff74c376043435 /spec/support/helpers | |
parent | 15c6e39026e0fbfc6a037262767db3d48e33aee1 (diff) | |
parent | 1ede6eb05712180149c2c2d8b45351f9ff4690a4 (diff) |
Merge branch 'ce-jej/group-saml-metadata-endpoint' into 'master'
[CE] Backport TokenAuthenticatable comparison method and stub_default_url_options
See merge request gitlab-org/gitlab-ce!19094
Diffstat (limited to 'spec/support/helpers')
-rw-r--r-- | spec/support/helpers/stub_configuration.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/support/helpers/stub_configuration.rb b/spec/support/helpers/stub_configuration.rb index 776119564ec..2851cd9733c 100644 --- a/spec/support/helpers/stub_configuration.rb +++ b/spec/support/helpers/stub_configuration.rb @@ -27,6 +27,11 @@ module StubConfiguration allow(Gitlab.config.gitlab).to receive_messages(to_settings(messages)) end + def stub_default_url_options(host: "localhost", protocol: "http") + url_options = { host: host, protocol: protocol } + allow(Rails.application.routes).to receive(:default_url_options).and_return(url_options) + end + def stub_gravatar_setting(messages) allow(Gitlab.config.gravatar).to receive_messages(to_settings(messages)) end |