O'Reilly logo

Pragmatic Unit Testing in Java 8 with JUnit by Jeff Langr, Andy Hunt, Dave Thomas

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

NetBeans

Navigate to the project properties page. Add a test package folder to correspond to the source folder; name it test:

images/netbeans/project_properties.png

Click OK to save the changes, then click File New File… from NetBeans’ main menu to open the New File dialog box:

images/netbeans/new_test_class.png

Select Unit Tests from the list of categories, then select Test for Existing Class from the list of file types. Click the Next button. You’ll see the rather busy New Test for Existing Class dialog box.

Enter the name of the class to test as iloveyouboss.ScoreCollection (or let NetBeans fill in the name by selecting ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required