Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

10 Testing and Profiling > Two-Minute Drill

Image TWO-MINUTE DRILL

Testing Applications with JUnit

Image NetBeans supports JUnit 3.x and JUnit 4.x.

Image NetBeans prompts on the first unit test being created for the JUnit version.

Image NetBeans automatically adds either JUnit 3.x or JUnit 4.x libraries to the classpath.

Image JUnit 4.x requires Java SE 5 or greater.

Image JUnit 4.x makes extensive use of annotations.

Image JUnit 3 and JUnit 4 conventions cannot be mixed in the same unit test case.

Image Empty JUnit tests are created by choosing File | New File and selecting JUnit Test from the JUnit category.

Image A JUnit for an existing class can be created by choosing File | New File and selecting Test For Existing Class from the JUnit category.

Image A test suite for an existing class can be created by choosing File | New File and selecting Test Suite.


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint