Class: CarrierWave::Test::Matchers::MiniMagickWrapper

Inherits:
Object
  • Object
show all
Defined in:
lib/carrierwave/test/matchers.rb

Overview

:nodoc:

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(filename) ⇒ MiniMagickWrapper

Returns a new instance of MiniMagickWrapper.



387
388
389
# File 'lib/carrierwave/test/matchers.rb', line 387

def initialize(filename)
  @image = ::MiniMagick::Image.open(filename)
end

Instance Attribute Details

#imageObject (readonly)

Returns the value of attribute image.



374
375
376
# File 'lib/carrierwave/test/matchers.rb', line 374

def image
  @image
end

Instance Method Details

#formatObject



383
384
385
# File 'lib/carrierwave/test/matchers.rb', line 383

def format
  image[:format]
end

#heightObject



379
380
381
# File 'lib/carrierwave/test/matchers.rb', line 379

def height
  image[:height]
end

#widthObject



375
376
377
# File 'lib/carrierwave/test/matchers.rb', line 375

def width
  image[:width]
end