capybara-screenshot
capybara-screenshot copied to clipboard
Screenshot in JSON Formatter
Hello there,
I am using "https://github.com/jenkinsci/cucumber-reports-plugin" for generating reports, which generates the reports based on the json output of cucumber execution.
However, the screenshots captured by this plugin aren't exported/embedded in json report.
Can you please take a look at this?
Regards, Anand
Sorry @anandchavan but you will need to look into this if you need this functionality. This is effectively a feature request.
Some sort of making json output useable with screenshot output info from this gem is
def self.output_error_parser output
arr = output.lines
if arr.count > 1
arr.map! {|line| line.gsub(/.*screenshot: /, '') }
arr[0] = arr[0].gsub(/html.*$/, 'html').chomp
arr[1] = arr[1].gsub(/png.*$/, 'png').chomp
return arr
else
return output
end
end
@anandchavan