I wanna do something like
java -enableassertions com.geeksanonymous.TestClass
How do I do this?
Right click to your project and select Properties -> Run -> Add new configuration
(select a name for the configuration, in my case I named it "assertion"). Then select VM options
and write -enableassertions
.
The easiest way is to use the Run properties. The property is labeled 'VM Options'.
This tutorial has more detailed info and screen shots from NetBeans 5.5. The dialog is very similar in the most recent release of NetBeans; 6.8, which is available today.