6

I currently try to implement parallel_tests for our Cucumber + Watir-WebDriver acceptance tests. As far it goes great.

However, we got used to nice HTML reports from Cucumber with embedded screenshots of failed scenarios. Cucumber creates reports as a single HTML file with all the features. But with parallel_tests, this HTML file is overwritten with the last called Cucumber process and thus incomplete.

Is it possible to generate several HTML reports or generate HTML reports per features file?

p0deje
  • 3,903
  • 1
  • 26
  • 37

2 Answers2

5

Put

default: --format html --out report<%= ENV['TEST_ENV_NUMBER'] %>.html

in ./config/cucumber.yml. Whey you run the tests, you will find report.html, report2.html (...) files in project root.

Željko Filipin
  • 56,372
  • 28
  • 94
  • 125
  • Not working for me: cucumber -p parallel features/IVA_features --out output/report <%= ENV['TEST_ENV_NUMBER'] %>.html -bash: %=: No such file or directory – Farooq Jun 29 '15 at 20:35
1

I don't think you have this out of the box. What we ended up doing was writing a new formatter.

https://github.com/cucumber/cucumber/wiki/Custom-Formatters

Bramha Ghosh
  • 6,504
  • 4
  • 30
  • 29