rajatthareja / ReportBuilder

Ruby gem to merge Cucumber JSON reports and build mobile-friendly HTML Test Report, JSON report and retry file.
https://reportbuilder.rajatthareja.com
MIT License
81 stars 47 forks source link

embedding images #87

Closed theog closed 5 years ago

theog commented 5 years ago

Just wondering why it was decided to embed images rather than just link, the report I'm building is getting really large, i was only able to successfully generate a portion of all features about 6% and that report html was over 100MB. Would be great to have an additional option to embed_images with default true. In saying that i will probably fork for now and submit PR if you feel this option is beneficial to others.

include_images = true
embed_images = false

❗️ Closed this as i realised the original json contains only the embedded image.

theog commented 5 years ago

Just for anyone who may have a similar concern as above, embed images bloats the json and html file and in my case a link directly the the asset was a much better solution.

Rather than using embed when creating a snapshot i outputted html that resulted in similar behaviour as in an image that provided materialize boxed behaviour.

  puts %{<div class="material-placeholder"><img class="materialboxed" data-caption="#{test_step.source.last.text}" width="250" src="./#{screen_shot.split('/').last}"></div>}