How to get the command "maven test:test" to delete test files before executing?

View: New views
1 Messages — Rating Filter:   Alert me  

How to get the command "maven test:test" to delete test files before executing?

by laredotornado :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

I'm using Maven 1.1 with Java 1.5 on a Mac 10.5.6.  In my test directory, I can run "maven test:test" to execute all of my unit tests.  I would like that when I type this command, the first thing that happens is that all files in the current directory matching "*.tmp" get deleted (in case a previous test run crashed).  How can I customize the "maven test:test" command to delete the temporary files before it starts its test run?

Thanks, - Dave