Thanx. This certainly helps. But just curious: The complete scenario is like this: We've developed a web application which contains a spring.properties property file. The properties in this file differ depending on the type of build (test, production) and the phase (test, packaging, integration-test).
The result from the test build is used for acceptance testing and should have it's own acceptance test spring.properties. During the test phase it should use another specialzed instance of spring.properties. As I understand from your post I can put this one in the test-resources. For integration testing I need the same spring.properties instance as during test phase. However the application deployed contains the acceptance test spring.properties instance. My thoughts were to deploy the application and overwrite the acceptance spring.properties with the one for unit and integration testing purposes and then start the application server and the integration test (We use Selenium for integration testing and test a deployed instance of our application). The production build has the same problems. During the test and integration-test phase the same spring.properties instance as in the test build is used. The production spring.properties in the end result however, isn't the same as the acceptance test properties from the test build. How do you resolve this? The files have the same name in the end result! How can I make sure the right spring.properties is included. My thoughts were to include a spring.properties.production and rename it to spring.properties if a production build is run, overwriting the default spring.properties which is for acceptance testing. I don't see how using test-resource does solve this problem. Any other thoughts anyone? If producing a test build the properties in the end artifact should -- View this message in context: http://www.nabble.com/m2%3A+renaming+file+before+including+in+jar-t1699650.html#a4621952 Sent from the Maven - Users forum at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]