Enabling Assertions in Eclipse
From EQUIS Lab Wiki
Assertions are one of the most useful tools available to software engineers to help debug their code. Unfortunately, Eclipse has assertion checking turned off by default. This means that even if assertions fail, no error will be produced.
To turn assertions on, go to Window|Preferences. In the dialogue that appears, select Installed JRE's. The dialogue should look like this:
Select your JRE, and click Edit. You will come to a dialogue that looks like this:
Enter -ea under Default VM Arguments. Click Ok to save the change.
Your assertions will now be checked when you run your programs under Eclipse.