Module: CarrierWave::Test::Matchers
- Defined in:
- lib/carrierwave/test/matchers.rb
Overview
These are some matchers that can be used in RSpec specs, to simplify the testing of uploaders.
Defined Under Namespace
Classes: BeIdenticalTo, BeNoLargerThan, HaveDimensions, HavePermissions
Instance Method Summary
collapse
Instance Method Details
#be_identical_to(expected) ⇒ Object
26
27
28
|
# File 'lib/carrierwave/test/matchers.rb', line 26
def be_identical_to(expected)
BeIdenticalTo.new(expected)
end
|
#be_no_larger_than(width, height) ⇒ Object
78
79
80
|
# File 'lib/carrierwave/test/matchers.rb', line 78
def be_no_larger_than(width, height)
BeNoLargerThan.new(width, height)
end
|
#have_dimensions(width, height) ⇒ Object
106
107
108
|
# File 'lib/carrierwave/test/matchers.rb', line 106
def have_dimensions(width, height)
HaveDimensions.new(width, height)
end
|
#have_permissions(expected) ⇒ Object
50
51
52
|
# File 'lib/carrierwave/test/matchers.rb', line 50
def have_permissions(expected)
HavePermissions.new(expected)
end
|