I have a module in my Java project with multiple integration tests. Two of them are UpgradeDatabase.java and CreateDatabase.java which are currently executed at each run in the pre-integration phase. I want to schedule these to run only once in a while (let's say monthly) because they take too long to execute (many DBs are created, etc.), How can I achieve this ? My failsafe plugin configuration looks like this (note, the skip.selenium.tests parameter is false):
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<forkMode>${tests.forkMode}</forkMode>
<skip>${skip.selenium.tests}</skip>
<environmentVariables>
...this area skipped...as it's non important
</environmentVariables>
<systemPropertyVariables>
<!--<rc.count.firefox>${rc.count.firefox}</rc.count.firefox>-->
<selenium.browser>firefox</selenium.browser>
<user.home>${env.USERPROFILE}</user.home>
</systemPropertyVariables>
</configuration>
<executions>
<!--before the tests-->
<execution>
<id>upgrade-the-database</id>
<configuration>
<includes>
<include>**/UpgradeDatabase.java</include>
</includes>
</configuration>
<phase>pre-integration-test</phase>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
<!--before the tests-->
<execution>
<id>recreate-the-database</id>
<configuration>
<testFailureIgnore>false</testFailureIgnore>
<includes>
<include>**/CreateDatabase.java</include>
</includes>
</configuration>
<phase>pre-integration-test</phase>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>