You could use test resource filtering to put the path into a resource file on the test classpath.
That way the IDE will pick up the same path. On Thursday, 13 March 2014, Alex Karasulu <akaras...@apache.org> wrote: > Hello, > > I've got a module that builds an executable jar file using the Maven > Assembly Plugin. I'm trying to setup an integration test (in the same > module) that runs this executable jar file as a separate process and > interacts with it. To fire up the executable jar file, my integration test > requires the path to the executable jar file. > > I'm trying to achieve this by passing a property to the integration-test > via system properties. This makes me feel really really dirty though and it > has issues: although the test runs on the CLI it does not in any IDE > without requiring further configuration (i.e. the property has to be > manually added to a run configuration). > > After googling around a bit and reading the documentation there seems to be > no other option for this scenario. In case I'm overlooking something, I > wanted to ask here if there is a better way to start up this executable jar > file or pass in the needed parameters to do so in the integration test? > > -- > Best Regards, > -- Alex > -- Sent from my phone