-
-
Notifications
You must be signed in to change notification settings - Fork 2k
No support for Spring Boot Test version 1.5.x #1242
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
Cucumber-JVM is community supported, see https://github.com/cucumber/cucumber-jvm#how-soon-will-my-ticket-be-fixed If you want to support the development of Cucumber-JVM by other means than providing pull requests, see https://cucumber.io/blog/2017/10/03/invest-in-cucumber BTW |
@vipinjose8683 you're lucky I'll need this myself soon. Would you mind building this branch locally and test driving it for a bit? https://github.com/cucumber/cucumber-jvm/tree/spring-support-bootstrap-with-annotation |
@mpkorstanje Thank you. I built the branch locally and tested it in my use case. The spring boot instance starts up as expected when I add the following class in my glue code. @SpringBootTest(webEnvironment=WebEnvironment.DEFINED_PORT)
public class SpringBootInstanceLauncher {
@Given("^there is a local spring boot instance of subject to test against$")
public void there_is_a_local_instance_of_subject_to_test_against() throws Throwable {
//This test method is to launch the embedded container that will be tested against
}
} (On a side note, i had to skip tests during maven install because test cases in "Examples: Pax Exam: Calculator Test" module was failing.) |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Summary
In spring boot test version 1.5.x, the only way to launch a spring boot instance with cucumber is to use @SpringBootTest annotation in one of the stepdef classes. But the cucumber does not support @SpringBootTest. As a result, the spring boot instance does not launch.
Expected Behavior
If the following code is included in the glue code then cucumber should launch a spring boot embedded container
Current Behavior
Spring Boot instance does not launch.
Possible Solution
#1061 ?
The above mentioned issue does not clearly state the importance and urgency of the requirement.
Context & Motivation
The workaround was to use the following set of annotations:
But @WebIntegrationTest (which was deprecated in v1.4) is removed from v1.5 as a single annotation @SpringBootTest achieves the same.
I use spring boot v1.5.x and cannot find any other way to do integration test with cucumber.
The text was updated successfully, but these errors were encountered: