Jason Thompson
Jason Thompson

Reputation: 4833

Is there a way to tell eclipse to ignore warnings from specific code folders?

This is a longshot question, so bear with me. :)

I like to have my code warning free so that I can quickly determine if I have a warning that truly needs to be dealt with. I have it set that if certain javadoc items are not correct, it will display a warning. In the team I work with, they are not concerned with javadoc warnings in the unit tests. These tests are always at src/test/java. Unfortunately if there is a warning in the test, it not only shows the warning icon on the code folder src/test/java, but also on the project itself. I'm tempted just to javadoc all of their unit tests, but it's not a good use of my time. Is there a way to tell eclipse to ignore warnings from src/test/java or trigger different warnings for my tests than for my implementation?

Upvotes: 0

Views: 984

Answers (2)

JRA_TLL
JRA_TLL

Reputation: 1361

There is at least one good answer in How to suppress Java warnings for specific directories or files such as generated code (using Project properties > Java Build Path > Compiler > Source)

Upvotes: 0

Richard Neish
Richard Neish

Reputation: 8806

You can use a working set to filter out the test code. Take a look at this answer: Filtering warnings in eclipse by filename

Upvotes: 1

Related Questions