A platform for community discussion. Free, open, simple.
Update `UploadCreator` specs to include cropping code path.
Guo Xiang Tan4b7c5ba162ca
diff --git a/spec/lib/upload_creator_spec.rb b/spec/lib/upload_creator_spec.rbindex 02861221a39..4238918225d 100644--- a/spec/lib/upload_creator_spec.rb+++ b/spec/lib/upload_creator_spec.rb@@ -31,7 +31,10 @@ RSpec.describe UploadCreator doit 'should store the upload with the right extension' doexpect do- UploadCreator.new(file, filename).create_for(user.id)+ UploadCreator.new(file, filename,+ force_optimize: true,+ type: UploadCreator::TYPES_TO_CROP.first+ ).create_for(user.id)end.to change { Upload.count }.by(1)upload = Upload.last