@@notification_tests = []
@@notification_tests.push lambda { |controller, current_user|
+ return nil if Rails.configuration.shell_in_a_box_url
AuthorizedKey.limit(1).where(authorized_user_uuid: current_user.uuid).each do
return nil
end
assert page.has_link?('Report a problem ...'), 'No link - Report a problem'
end
end
+
+ test "no SSH public key notification when shell_in_a_box_url is configured" do
+ Rails.configuration.shell_in_a_box_url = 'example.com'
+ visit page_with_token('job_reader')
+ click_link 'notifications-menu'
+ assert page.has_no_link?('Click here to set up an SSH public key for use with Arvados.')
+ assert page.has_link?('Click here to learn how to run an Arvados Crunch pipeline')
+ end
end