Maintenance: Work around timeouts caused by the sanitizer in slow CI environments.

This commit is contained in:
Martin Gruner 2021-09-23 15:14:15 +02:00
parent 95571b70c9
commit 60c0b08d21

View file

@ -1236,6 +1236,12 @@ RSpec.describe Channel::EmailParser, type: :model do
end end
describe 'XSS protection' do describe 'XSS protection' do
before do
# XSS processing may run into a timeout on slow CI systems, so turn the timeout off for the test.
stub_const("#{HtmlSanitizer}::PROCESSING_TIMEOUT", nil)
end
let(:article) { described_class.new.process({}, raw_mail).second } let(:article) { described_class.new.process({}, raw_mail).second }
let(:raw_mail) { <<~RAW.chomp } let(:raw_mail) { <<~RAW.chomp }