Debugging maven junit tests with filtered resources?
Posted
by hstoerr
on Stack Overflow
See other posts from Stack Overflow
or by hstoerr
Published on 2010-05-18T08:47:50Z
Indexed on
2010/05/18
9:11 UTC
Read the original article
Hit count: 262
We are using filtered testResources in JUnit-tests that are usually executed by the maven surefire plugin. That is, the pom contains a section
<build>
<testResources>
<testResource>
<directory>src/test/resources</directory>
<filtering>true</filtering>
</testResource>
</testResources>
...
How can I run such JUnit-tests in the debugger? If I execute the tests in eclipse the tests fail since the test resources are not filtered. If the filtered test resources would be written somewhere into the target directory, I could just use this as an additional source path - but this is not the case. If I try to run the maven build in eclipse with Debug As / maven test , the build does not stop in the breakpoints. Any other ideas?
© Stack Overflow or respective owner