2010-12-03 31 views
2

這就是我想要做的事:如何將maven-surefire-plugin執行分割爲兩個獨立的執行?

[...] 
<plugin> 
    <groupId>org.apache.maven.plugins</groupId> 
    <artifactId>maven-surefire-plugin</artifactId> 
    <version>2.5</version> 
    <configuration> 
    <excludes> 
     <exclude>**/*JSFTest.java</exclude> 
    </excludes> 
    <executions> 
     <execution> 
     <phase>integration-test</phase> 
     <goals> 
      <goal>test</goal> 
     </goals> 
     <configuration> 
      <excludes> 
      <!-- intentionally empty to override configuration above --> 
      </excludes> 
      <includes> 
      <include>**/*JSFTest.java</include> 
      </includes> 
     </configuration> 
     </execution> 
    </executions> 
    </plugin> 

我定製<execution>具有運行在容器中的所有JSF相關的測試。不幸的是,它沒有找到任何測試。看起來像<includes>不起作用。而<excludes>在階段test有效排除這些測試。這裏有什麼問題?

回答

2

更多的自我提醒:;-)

<excludes> 
    <exclude>none</exclude> 
<excludes> 

空排除不起作用。