Class: Gnawrnip::StepScreenshot
- Inherits:
-
TurnipFormatter::StepTemplate::Exception
- Object
- TurnipFormatter::StepTemplate::Exception
- Gnawrnip::StepScreenshot
- Defined in:
- lib/gnawrnip/step_screenshot.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.css ⇒ Object
8 9 10 |
# File 'lib/gnawrnip/step_screenshot.rb', line 8 def self.css File.read(File.dirname(__FILE__) + '/gnawrnip.css') end |
Instance Method Details
#build(example) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/gnawrnip/step_screenshot.rb', line 12 def build(example) images = example.[:gnawrnip][:screenshot] case images.length when 0 '' when 1 single_image(images.first) else animation_image(images) end end |