diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-18 13:16:36 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-18 13:16:36 +0000 |
commit | 311b0269b4eb9839fa63f80c8d7a58f32b8138a0 (patch) | |
tree | 07e7870bca8aed6d61fdcc810731c50d2c40af47 /spec/requests/groups | |
parent | 27909cef6c4170ed9205afa7426b8d3de47cbb0c (diff) | |
download | gitlab-ce-311b0269b4eb9839fa63f80c8d7a58f32b8138a0.tar.gz |
Add latest changes from gitlab-org/gitlab@14-5-stable-eev14.5.0-rc42
Diffstat (limited to 'spec/requests/groups')
-rw-r--r-- | spec/requests/groups/email_campaigns_controller_spec.rb | 10 | ||||
-rw-r--r-- | spec/requests/groups/settings/applications_controller_spec.rb | 20 |
2 files changed, 29 insertions, 1 deletions
diff --git a/spec/requests/groups/email_campaigns_controller_spec.rb b/spec/requests/groups/email_campaigns_controller_spec.rb index 4d630ef6710..9ed828d1a9a 100644 --- a/spec/requests/groups/email_campaigns_controller_spec.rb +++ b/spec/requests/groups/email_campaigns_controller_spec.rb @@ -94,7 +94,7 @@ RSpec.describe Groups::EmailCampaignsController do describe 'track parameter' do context 'when valid' do - where(track: Namespaces::InProductMarketingEmailsService::TRACKS.keys.without(:experience)) + where(track: [Namespaces::InProductMarketingEmailsService::TRACKS.keys.without(:experience), Namespaces::InviteTeamEmailService::TRACK].flatten) with_them do it_behaves_like 'track and redirect' @@ -117,6 +117,10 @@ RSpec.describe Groups::EmailCampaignsController do with_them do it_behaves_like 'track and redirect' end + + it_behaves_like 'track and redirect' do + let(:track) { Namespaces::InviteTeamEmailService::TRACK.to_s } + end end context 'when invalid' do @@ -124,6 +128,10 @@ RSpec.describe Groups::EmailCampaignsController do with_them do it_behaves_like 'no track and 404' + + it_behaves_like 'no track and 404' do + let(:track) { Namespaces::InviteTeamEmailService::TRACK.to_s } + end end end end diff --git a/spec/requests/groups/settings/applications_controller_spec.rb b/spec/requests/groups/settings/applications_controller_spec.rb new file mode 100644 index 00000000000..74313491414 --- /dev/null +++ b/spec/requests/groups/settings/applications_controller_spec.rb @@ -0,0 +1,20 @@ +# frozen_string_literal: true + +require 'spec_helper' + +RSpec.describe Groups::Settings::ApplicationsController do + let_it_be(:user) { create(:user) } + let_it_be(:group) { create(:group) } + let_it_be(:application) { create(:oauth_application, owner_id: group.id, owner_type: 'Namespace') } + let_it_be(:show_path) { group_settings_application_path(group, application) } + let_it_be(:create_path) { group_settings_applications_path(group) } + + before do + sign_in(user) + group.add_owner(user) + end + + include_examples 'applications controller - GET #show' + + include_examples 'applications controller - POST #create' +end |