summaryrefslogtreecommitdiff
path: root/spec/helpers
diff options
context:
space:
mode:
authorNick Thomas <nick@gitlab.com>2018-08-15 09:29:20 +0000
committerNick Thomas <nick@gitlab.com>2018-08-15 09:29:20 +0000
commit9b718a761f1601394c3a1e0a15c7855d7eec6ac3 (patch)
tree79e1e49fcc38c61b494e1ba431e83e021e91b8fd /spec/helpers
parentc87ca8322636db69b6f097336f163d0373bb415e (diff)
parentb6ba8cc696a45e58bde24a592a9c315a0eb16744 (diff)
downloadgitlab-ce-9b718a761f1601394c3a1e0a15c7855d7eec6ac3.tar.gz
Merge branch 'add-user_show_add_ssh_key_message-application-setting' into 'master'
Add a "user_show_add_ssh_key_message" application setting for use with SSH certificates Closes #49953 See merge request gitlab-org/gitlab-ce!21027
Diffstat (limited to 'spec/helpers')
-rw-r--r--spec/helpers/button_helper_spec.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/spec/helpers/button_helper_spec.rb b/spec/helpers/button_helper_spec.rb
index 630f3eff258..0c0a0003231 100644
--- a/spec/helpers/button_helper_spec.rb
+++ b/spec/helpers/button_helper_spec.rb
@@ -79,6 +79,18 @@ describe ButtonHelper do
end
end
+ context 'without an ssh key on the user and user_show_add_ssh_key_message unset' do
+ before do
+ stub_application_setting(user_show_add_ssh_key_message: false)
+ end
+
+ it 'there is no warning on the dropdown description' do
+ description = element.search('.dropdown-menu-inner-content').first
+
+ expect(description).to be_nil
+ end
+ end
+
context 'with an ssh key on the user' do
before do
create(:key, user: user)