VOOZH about

URL: https://www.javacodegeeks.com/2021/06/using-the-quarkus-dev-mode-for-non-quarkus-projects.html

⇱ Using the Quarkus dev mode for non-Quarkus projects - Java Code Geeks


The Quarkus dev mode increases our development productivity and especially reduces the turnaround times how long it takes to get test feedback. For Quarkus projects, this is a huge benefit. However, with some hacky workarounds, it’s possible to run the tests of a plain Java project also in a similar way.

In this video, I’m showing how to add the Quarkus Maven plugin to non-Quarkus projects:

You can check out the system project in Quarkus version 2.0.0.CR3 on GitHub.

In the system test project, I’ve added the following pom.xml snippet:

<profiles>
 <profile>
 <id>test</id>
 <properties>
 <quarkus.version>2.0.0.CR3</quarkus.version>
 <debug>false</debug>
 <quarkus.native.builder-image>ignored</quarkus.native.builder-image>
 </properties>
 <dependencies>
 <dependency>
 <groupId>io.quarkus</groupId>
 <artifactId>quarkus-core</artifactId>
 <version>${quarkus.version}</version>
 </dependency>
 </dependencies>
 <build>
 <plugins>
 <plugin>
 <groupId>io.quarkus</groupId>
 <artifactId>quarkus-maven-plugin</artifactId>
 <extensions>true</extensions>
 <version>${quarkus.version}</version>
 <executions>
 <execution>
 <goals>
 <goal>build</goal>
 </goals>
 </execution>
 </executions>
 </plugin>
 </plugins>
 </build>
 </profile>
</profiles>

In this way, we have to activate the test Maven profile when executing the Quarkus plugin:

mvn quarkus:dev -Ptest

Published on Java Code Geeks with permission by Sebastian Daschner, partner at our JCG program. See the original article here: Using the Quarkus dev mode for non-Quarkus projects (Video)

Opinions expressed by Java Code Geeks contributors are their own.

Do you want to know how to develop your skillset to become a Java Rockstar?
Subscribe to our newsletter to start Rocking right now!
To get you started we give you our best selling eBooks for FREE!
1. JPA Mini Book
2. JVM Troubleshooting Guide
3. JUnit Tutorial for Unit Testing
4. Java Annotations Tutorial
5. Java Interview Questions
6. Spring Interview Questions
7. Android UI Design
and many more ....
I agree to the Terms and Privacy Policy

Thank you!

We will contact you soon.

Tags
quarkus
πŸ‘ Photo of Sebastian Daschner
Sebastian Daschner
June 24th, 2021Last Updated: January 3rd, 2022
0 93 1 minute read

Sebastian Daschner

Sebastian Daschner is a self-employed Java consultant and trainer. He is the author of the book 'Architecting Modern Java EE Applications'. Sebastian is a Java Champion, Oracle Developer Champion and JavaOne Rockstar.
Subscribe

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 Comments
Oldest
Newest Most Voted
Back to top button
Close
wpDiscuz