Class: Approvals::Reporters::ImageMagickReporter
- Inherits:
-
Object
- Object
- Approvals::Reporters::ImageMagickReporter
- Includes:
- Singleton
- Defined in:
- lib/approvals/reporters/image_reporter/image_magick_reporter.rb
Instance Method Summary collapse
- #create_command_line(received, approved) ⇒ Object
- #report(received, approved) ⇒ Object
- #working_in_this_environment? ⇒ Boolean
Instance Method Details
#create_command_line(received, approved) ⇒ Object
10 11 12 |
# File 'lib/approvals/reporters/image_reporter/image_magick_reporter.rb', line 10 def create_command_line(received, approved) "compare #{received} #{approved} -compose Src x:" end |
#report(received, approved) ⇒ Object
14 15 16 |
# File 'lib/approvals/reporters/image_reporter/image_magick_reporter.rb', line 14 def report(received, approved) system(create_command_line(received, approved)) end |
#working_in_this_environment? ⇒ Boolean
6 7 8 |
# File 'lib/approvals/reporters/image_reporter/image_magick_reporter.rb', line 6 def working_in_this_environment? Approvals::SystemCommand.exists? "compare" end |