Maven - How to compile tests without running them ?

前端 未结 7 1609
时光说笑
时光说笑 2021-01-30 06:16

Is there a way in Maven to compile the tests without running them ? I want to use the IDE to run specific tests and not all of them.

7条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-30 06:24

    How about the test-compile lifecycle phase? It doesn't require any test skipping, because it occurs before the test phase. I.e.,

    $ mvn test-compile
    

    And done.

    Introduction to the Build Lifecycle explains further.

提交回复
热议问题