testFailureIgnore для 1 конкретного теста c - PullRequest
0 голосов
/ 08 апреля 2020

Я ищу что-то похожее на testFailureIgnore в maven-surefire-plugin, которое будет применяться только в случае сбоя одного указанного c теста. Есть ли способ выполнить это sh?

1 Ответ

0 голосов
/ 08 апреля 2020

Я нашел ответ здесь: https://rmannibucau.metawerx.net/post/maven-surefire-debugging-execution

Их пример ниже:

<plugin>
 <artifactId>maven-surefire-plugin</artifactId>
 <executions>
   <execution>
     <id>applicationcomposer</id>
     <goals>
       <goal>test</goal>
     </goals>
     <configuration>
       <groups>com.github.rmannibucau.surefire.executions.Group1</groups>
       <skip>${maven.test.skip}</skip>
       <systemPropertyVariables>
         <openejb.jul.forceReload>true</openejb.jul.forceReload>
       </systemPropertyVariables>
     </configuration>
   </execution>
   <execution>
     <id>arquillian</id>
     <goals>
       <goal>test</goal>
     </goals>
     <configuration>
       <excludedGroups>com.github.rmannibucau.surefire.executions.Group1</excludedGroups>
       <skip>${maven.test.skip}</skip>
       <systemPropertyVariables>
         <java.io.tmpdir>${project.build.directory}</java.io.tmpdir>
       </systemPropertyVariables>
     </configuration>
   </execution>
 </executions>
 <configuration>
   <skip>true</skip>
   <failIfNoTests>false</failIfNoTests>
   <reuseForks>true</reuseForks>
   <forkCount>1</forkCount>
 </configuration>
</plugin>
...