Sha256: b18b21944d5d283cacd441f2de974ed358697dcaba85b864287f9944417a631a
Contents?: true
Size: 362 Bytes
Versions: 28
Compression:
Stored size: 362 Bytes
Contents
require 'rails_helper' require 'paperclip/matchers' RSpec.describe Image, type: :model do include Paperclip::Shoulda::Matchers it { should have_attached_file(:file) } it { should validate_attachment_content_type(:file). allowing('image/png', 'image/gif', 'image/jpeg') } it { should validate_attachment_size(:file).less_than(2.megabytes) } end
Version data entries
28 entries across 28 versions & 1 rubygems