diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-29 01:05:40 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-29 01:05:44 +0300 |
commit | f5897da89ca63facbef54c23cff894f2bbe8e644 (patch) | |
tree | 9671f60e71b3cb78705a211977870fb1c5a4b354 /spec/support/shared_examples | |
parent | 10d9a3bf50cca85dd857c5306a34d7a6032580e6 (diff) |
Add latest changes from gitlab-org/security/gitlab@15-4-stable-ee
Diffstat (limited to 'spec/support/shared_examples')
2 files changed, 7 insertions, 1 deletions
diff --git a/spec/support/shared_examples/controllers/concerns/web_hooks/integrations_hook_log_actions_shared_examples.rb b/spec/support/shared_examples/controllers/concerns/web_hooks/integrations_hook_log_actions_shared_examples.rb index 62c9c3508a8..56a5dcb10b2 100644 --- a/spec/support/shared_examples/controllers/concerns/web_hooks/integrations_hook_log_actions_shared_examples.rb +++ b/spec/support/shared_examples/controllers/concerns/web_hooks/integrations_hook_log_actions_shared_examples.rb @@ -26,7 +26,7 @@ RSpec.shared_examples WebHooks::HookLogActions do describe 'POST #retry' do it 'executes the hook and redirects to the service form' do - stub_request(:post, web_hook.url) + stub_request(:post, web_hook.interpolated_url) expect_next_found_instance_of(web_hook.class) do |hook| expect(hook).to receive(:execute).and_call_original diff --git a/spec/support/shared_examples/models/integrations/has_web_hook_shared_examples.rb b/spec/support/shared_examples/models/integrations/has_web_hook_shared_examples.rb index 2f693edeb53..e309aa50c6e 100644 --- a/spec/support/shared_examples/models/integrations/has_web_hook_shared_examples.rb +++ b/spec/support/shared_examples/models/integrations/has_web_hook_shared_examples.rb @@ -37,6 +37,12 @@ RSpec.shared_examples Integrations::HasWebHook do end end + describe '#url_variables' do + it 'returns a string' do + expect(integration.url_variables).to be_a(Hash) + end + end + describe '#hook_ssl_verification' do it 'returns a boolean' do expect(integration.hook_ssl_verification).to be_in([true, false]) |