Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include timestamps for test cases during conversion #103

Open
nayanab123 opened this issue Jul 22, 2024 · 0 comments
Open

Include timestamps for test cases during conversion #103

nayanab123 opened this issue Jul 22, 2024 · 0 comments

Comments

@nayanab123
Copy link

🤔 What's the problem you're trying to solve?

The JSON file generated by the standalone json-formatter does not follow the same JSON schema as the in-built json formatter.
The property I'm specifically looking for is the start_timestamp for scenarios. This information is available in ndjson file generated by the in-built message formatter. However, it is omitted while transforming to JSON.

✨ What's your proposed solution?

Ideally, update the standalone formatter to follow the same JSON Schema as in-built JsonFormatter.
Temporary solution -> ensure start time stamps are also included in the JSON file generated after conversion from ndjson.

⛏ Have you considered any alternatives or workarounds?

I could not find any alternatives that work for maven projects.

📚 Any additional context?

Quite a lot of reporting libraries/plugins that generate stylized HTML reports for cucumber use JSON as the input. I'm yet to find one that supports ndjson inputs.
The plugin that I'm using right now takes multiple json files containing the results of reruns as input and generate a single HTML report combining the data in them. This helps in creating a consolidated report for a complete run including reruns on failed testcases. For this purpose, the plugin checks the start_timestamp attribute for testcases in cucumber JSON report to decide on how to merge the data for reporting. Since the timestamp is missing in json files created by the standalone formatter, this functionality fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant