Maintenance: Capybara S/Mime tests improvements

This commit is contained in:
Mantas 2020-09-11 09:17:27 +03:00 committed by Thorsten Eckel
parent 97fc711370
commit 08ef240843

View file

@ -25,6 +25,8 @@ RSpec.describe 'Ticket Create', type: :system do
context 'S/MIME', authenticated_as: :authenticate do
def authenticate
Setting.set('smime_integration', true)
Setting.set('smime_config', smime_config) if defined?(smime_config)
current_user
end
@ -193,10 +195,6 @@ RSpec.describe 'Ticket Create', type: :system do
let(:smime_config) { {} }
before do
Setting.set('smime_config', smime_config)
end
shared_examples 'security defaults example' do |sign:, encrypt:|
it "security defaults sign: #{sign}, encrypt: #{encrypt}" do