Skip to content

Message based json formatter #2888

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

Open
wants to merge 45 commits into
base: main
Choose a base branch
from
Open

Conversation

mpkorstanje
Copy link
Contributor

@mpkorstanje mpkorstanje commented May 24, 2024

🤔 What's changed?

Replace the JsonFormatter with the message based implementation from cucumber-json-formatter.

This achieves several goals:

  • Move the internal code base away from the events from the plugin module.
  • Extract common parts of Cucumber into modules that can be shared.
  • Allows for more rigorous testing of a poorly defined format

🏷️ What kind of change is this?

  • 🏦 Refactoring/debt/DX (improvement to code design, tooling, etc. without changing behaviour)

♻️ Anything particular you want feedback on?

The Cucumber JSON report is a de facto standard without a specification. And the existing tests did not quite cover everything. While the new implementation now has 150+ test cases, it is not impossible that something was structurally overlooked.

If you do find a problem after release please create a new issue.

📋 Checklist:

  • I agree to respect and uphold the Cucumber Community Code of Conduct
  • I've changed the behaviour of the code
    • I have added/updated tests to cover my changes.
  • My change requires a change to the documentation.
    • I have updated the documentation accordingly.
  • Users should know about my change
    • I have added an entry to the "Unreleased" section of the CHANGELOG, linking to this pull request.

…rmatter

# Conflicts:
#	cucumber-bom/pom.xml
#	cucumber-core/src/main/java/io/cucumber/core/runner/CachingGlue.java
#	cucumber-core/src/test/java/io/cucumber/core/backend/StubHookDefinition.java
#	cucumber-core/src/test/java/io/cucumber/core/plugin/HtmlFormatterTest.java
#	cucumber-core/src/test/java/io/cucumber/core/plugin/JsonFormatterTest.java
…rmatter

# Conflicts:
#	cucumber-bom/pom.xml
#	cucumber-core/src/test/java/io/cucumber/core/backend/StubStepDefinition.java
@mpkorstanje mpkorstanje changed the title Message based json formatter Message based json formatter Jul 17, 2025
@mpkorstanje mpkorstanje marked this pull request as ready for review July 24, 2025 19:30
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

Successfully merging this pull request may close these issues.

1 participant