I have a Spring MVC project using IntelliJ IDEA 14 as my IDE (I'm new to IntelliJ IDEA; I used Eclipse).
My main Java code is in folder src/main
, and the unit test code is in src/test
. While deploying the project, I found that all the unit tests are executed.
How can I skip all the unit tests while deploying the project into Tomcat?
to toggle the Skip tests mode. On the Runner page, select Skip tests and click OK. IntelliJ IDEA de-activates the test goal under the Lifecycle node. The appropriate message notifying that tests are skipped is displayed in the Run tool window when you execute other goals.
To skip running the tests for a particular project, set the skipTests property to true. You can also skip the tests via the command line by executing the following command: mvn install -DskipTests.
When creating a maven configuration for the project. On the Runner tab you can click on skip test checkbox as below :
It helped me a lot!
In case you are using Maven
, on the View
> Tool Windows
> Maven Projects
click on the button shown below ( called Skip Tests Mode
). Essentially it is taking the test
phase out of the lifecycle when you say run package
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With