cucumber-attic / gherkin2

A fast Gherkin parser in Ragel (The parser behind Cucumber)
MIT License
381 stars 220 forks source link

Change the java JSONFormatter to handle embedding text in the report correctly #269

Closed brasmusson closed 11 years ago

brasmusson commented 11 years ago

The java JSONFormatter does not handle calls to write() correctly. The formatter expects them after the result() call, but if a step definition uses write() calls to embed text in the report, they will occur after the match() call but before the result() call. This is the root cause of the following issue in Cucumber-JVM: https://github.com/cucumber/cucumber-jvm/issues/565 Change the java JSONFormatter so that it can handle calls to write() after the call to match() but before the call to result().