Skip to content

fix: use Surefire engine filtering instead of -Dtest=! for scenario runs - #2

Merged
arun279 merged 2 commits into
mainfrom
fix/surefire-engine-filtering
Apr 14, 2026
Merged

fix: use Surefire engine filtering instead of -Dtest=! for scenario runs#2
arun279 merged 2 commits into
mainfrom
fix/surefire-engine-filtering

Conversation

@arun279

@arun279 arun279 commented Apr 14, 2026

Copy link
Copy Markdown
Owner

Replace -Dtest=!RunnerClass with -Dincludejunit5engines=cucumber when running specific scenarios. The old approach excluded the runner class but ran every other test class in the project. Engine filtering ensures only the Cucumber engine executes.

Also read cucumber.glue from junit-platform.properties (or a new VS Code setting) so the engine can find step definitions without relying on @ConfigurationParameter annotations on the excluded runner class.

arun279 added 2 commits April 13, 2026 22:04
Replace -Dtest=!RunnerClass with -Dincludejunit5engines=cucumber when
running specific scenarios. The old approach excluded the runner class
but ran every other test class in the project. Engine filtering ensures
only the Cucumber engine executes.

Also read cucumber.glue from junit-platform.properties (or a new VS Code
setting) so the engine can find step definitions without relying on
@ConfigurationParameter annotations on the excluded runner class.
@arun279
arun279 merged commit 8c34e33 into main Apr 14, 2026
1 check passed
@arun279
arun279 deleted the fix/surefire-engine-filtering branch April 14, 2026 03:25
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