I have a test resource that lives in resources/src/test/dir/sample.json
, and it needs to move to /tmp/data/sample.json
before unit tests can run. I want to use Maven to automate moving this file, without interfering with other test resources that need to move to target. The reason for this is that in production this file comes from outside the jar.
Looking at Maven's resource:testResources
goal here and also the plugin. I'm not sure where to specify the outputDirectory
, especially without interfering with anything else.
Will post more as I research, but I'm particularly afraid there's going to be several ways to do this and it's not going to be obvious which is the most conventional.