cucumber-attic / gherkin

Cross platform parser for the Gherkin language. Used by Cucumber to parse .feature files.
252 stars 126 forks source link

NDJSON events do not contain timestamp or series #258

Closed mattwynne closed 7 years ago

mattwynne commented 7 years ago

I'm working to bring the schemas in https://github.com/cucumber/cucumber/tree/master/event-protocol up to date with the messages emitted by the gherkin command-line tool.

I've noticed that while the docs for that protocol (rightly, IMO) mandate the timestamp and series attributes for all messages, the messages emitted by this tool do not contain either of those.

If we were to add them to the messages output by the tool, it would invalidate the sample data in testdata/good/*.ndjson. Since the values for series and timestamp will be dynamically generated at run-time and are non-deterministic, we won't be able to use static values for them in the test data.

I'm not sure how to resolve this. How are those testdata files used? Could the tools that check them against the actual output be made more sophisticated to be flexible about the exact values of timestamp / series? What other options do we have?

mattwynne commented 7 years ago

See https://github.com/cucumber/cucumber/pull/124 for the schema for this event that includes the timestamp and series attributes.

aslakhellesoy commented 7 years ago

This issue was moved to cucumber/cucumber#135