Update `UploadCreator` specs to include cropping code path.
This commit is contained in:
parent
fae8757cd4
commit
4b7c5ba162
|
@ -31,7 +31,10 @@ RSpec.describe UploadCreator do
|
||||||
|
|
||||||
it 'should store the upload with the right extension' do
|
it 'should store the upload with the right extension' do
|
||||||
expect do
|
expect 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)
|
end.to change { Upload.count }.by(1)
|
||||||
|
|
||||||
upload = Upload.last
|
upload = Upload.last
|
||||||
|
|
Loading…
Reference in New Issue