0
메이븐 통합 테스트 및 테스트에 정의 된 2 세트의 테스트가 있습니다.메이븐 - 통합 통합 및 유닛 테스트
내가 maven test
을 실행하면 - 내가 maven integration-test
를 실행하면 내 테스트
을 실행 - 모두 실행
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.4.3</version>
<executions>
<execution>
<id>default-test</id>
<configuration>
<forkMode>always</forkMode>
<excludes>
<exclude>**/TC_Integration*</exclude>
</excludes>
<includes>
<include>**/TC_*</include>
</includes>
</configuration>
</execution>
<execution>
<id>integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>test</goal>
</goals>
<configuration>
<excludes>
<exclude>**/TC_Unit*</exclude>
</excludes>
<includes>
<include>**/TC_*</include>
</includes>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
수 있도록 모두 모든 시간을 실행하는 가장 좋은 방법은 무엇입니까? 나는 주로 maven install
이 둘 다 실행되기를 원하지만 그렇지 않습니다.
'mvn verify'은 어떻게됩니까? – chrylis
이미 제안 된대로 maven-failsafe-plugin을 처음 사용하는 경우 이름 지정 규칙을 따라야합니다.이 규칙은 삶이 더 쉬워집니다 ... 단위 테스트 :'* Test.java *'통합 테스트'* IT.java' ... 그리고 @chrylis에 의해 이미 언급 한대로'mvn verify '를 사용하면 다른 것들을 종료하거나 클린업 할 때 통합 테스트에 때때로 필요한'post-integration-test' 단계가 실행되지 않습니다. – khmarbaise
테스트 이름을 변경할 수 없습니다. – mikeb