Search code examples
javaeclipsecode-coverageeclemma

Ignore code coverage for unit tests in EclEmma


I have configured EclEmma not to instrument my unit tests which works fine. However, the editor still highlights the test code as not covered. I want no highlighting in unit tests because they are not instrumented to detect coverage. How can I do this?


Solution

  • I did the following steps:

    1. Go to Preferences->Java->Code Coverage and
    2. set the "Only path entries matching" option to src/main/java

    It seems to work nicely.