docbrown/spec/support/initializers/image_processing.rb
rhymes a798bd2f7d
[15 min fix] Fallback to the image URL if Cloudinary/Imgproxy are not configured (#13767)
* Fallback to the image URL if neither Cloudinary nor Imgproxy are configured

* Fix specs

* Cloudinary api_secret is required

* Update spec/models/message_spec.rb

Co-authored-by: Michael Kohl <citizen428@dev.to>

Co-authored-by: Michael Kohl <citizen428@dev.to>
2021-05-19 15:03:20 +02:00

8 lines
391 B
Ruby

RSpec.configure do |config|
config.before(:each, cloudinary: true) do |_example|
allow(Cloudinary.config).to receive(:cloud_name).and_return("CLOUD_NAME")
allow(Cloudinary.config).to receive(:api_key).and_return("API_KEY")
allow(Cloudinary.config).to receive(:api_secret).and_return("API_SECRET")
allow(Cloudinary.config).to receive(:secure).and_return("SECURE")
end
end