Repository navigation
Release v3.0.0
Backward incompatible changes
- Dropped support for Java 17. JGiven now requires Java 21 or higher.
- Dropped module jgiven-spock
Deprecated modules
-
Deprecated
jgiven-junit5module in favor ofjgiven-junit6. Thejgiven-junit6module provides full JUnit 5 support and is also compatible with JUnit 6, enabling forward compatibility. Existing JUnit 5 tests usingjgiven-junit5will continue to work, but new projects should usejgiven-junit6.- Use
com.tngtech.jgiven.junit6.ScenarioTest,com.tngtech.jgiven.junit6.SimpleScenarioTest, andcom.tngtech.jgiven.junit6.DualScenarioTestinstead of the junit5 variants.
- Use
-
Deprecated
jgiven-spring-junit5module for Spring 7.x compatibility. A newjgiven-spring-junit6module has been introduced that supports Spring 7.x.- The
jgiven-spring-junit5module will continue to support Spring 6.x but is deprecated for users wanting to upgrade to Spring 7.x or later. - Use
com.tngtech.jgiven.integration.spring.junit6.SpringScenarioTest,com.tngtech.jgiven.integration.spring.junit6.SimpleSpringScenarioTest, andcom.tngtech.jgiven.integration.spring.junit6.DualSpringScenarioTestinstead of the junit5 variants.
- The
New features
- JGiven is now capable of generating its reports in Asciidoc format. Huge thanks to @johtor for sketching this
feature. #2211 - Added
jgiven-junit6module with support for both JUnit 5 and JUnit 6. This module provides API compatibility with JUnit 5 and enables migration to JUnit 6 when ready. - Added
jgiven-spring-junit6module with support for Spring 7.x while maintaining backward compatibility with JUnit 5. - Added
JGivenSpringExtension(injgiven-spring-junit5andjgiven-spring-junit6) that installs JGiven's
SpringStageCreatorvia a JUnit extension callback, so that Spring dependency injection into JGiven stages keeps
working even when a test declares@TestExecutionListenerswith the defaultREPLACE_DEFAULTSmerge mode. The Spring
scenario test base classes now register this extension
automatically. #2193
Fixed issues
-
Spring's
@TestExecutionListenerannotation no longer breaks JGiven's Spring context initialization. Previously,
declaring@TestExecutionListeners(which defaults toREPLACE_DEFAULTS) removed Spring's
DependencyInjectionTestExecutionListener, so theBeanFactoryAwarecallback that JGiven relied on to install its
SpringStageCreatornever fired, leaving@Autowiredstage beans uninjected. JGiven now installs the
SpringStageCreatorthrough its own JUnit extension, independent of any
TestExecutionListener. #2193Note, due an issue in the release process the released only points quite to the commit that was pushed to the respective artifact repositories. The last common commit is 8640fba