diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-22 12:09:43 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-22 12:09:43 +0300 |
commit | 1086ac5177a6762ac14bccc6ce5584781bd44d1c (patch) | |
tree | 9475118811efc3edc219bddd3c2e780e095c3056 /spec/features/protected_branches_spec.rb | |
parent | c8eee7e7e81f1d5ddaf0802140c1ca49587bd735 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/features/protected_branches_spec.rb')
-rw-r--r-- | spec/features/protected_branches_spec.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/features/protected_branches_spec.rb b/spec/features/protected_branches_spec.rb index f0707610c3f..d8d9ccb5c6f 100644 --- a/spec/features/protected_branches_spec.rb +++ b/spec/features/protected_branches_spec.rb @@ -9,6 +9,10 @@ RSpec.describe 'Protected Branches', :js do let(:admin) { create(:admin) } let(:project) { create(:project, :repository) } + before do + stub_feature_flags(deploy_keys_on_protected_branches: false) + end + context 'logged in as developer' do before do project.add_developer(user) @@ -163,4 +167,14 @@ RSpec.describe 'Protected Branches', :js do include_examples "protected branches > access control > CE" end end + + context 'when the users for protected branches feature is off' do + before do + stub_licensed_features(protected_refs_for_users: false) + end + + include_examples 'when the deploy_keys_on_protected_branches FF is turned on' do + let(:all_dropdown_sections) { %w(Roles Deploy\ Keys) } + end + end end |