Testing use cases with Quarkus and Cucumber
While implementing the Application hexagon in Chapter 7, Building the Application Hexagon, we used Cucumber to aid us in shaping and testing our use cases. By leveraging the Behavior-Driven Design techniques provided by Cucumber, we could express use cases in a declarative way. Now, we need to integrate Cucumber so that it works with Quarkus:
- The first step is to add the Quarkus testing dependencies to the
pom.xml
file from the Application hexagon:<dependency> <groupId>io.quarkiverse.cucumber</groupId> <artifactId>quarkus-cucumber</artifactId> <version>0.3.0</version> <scope>test</scope> </dependency> <dependency> <groupId>io.quarkus</groupId> <artifactId>quarkus-junit5</artifactId> <scope>test</scope> </dependency>
The
quarkus-cucumber
dependency...