Using Junit to test your code

Part One

Read the NetBeans tutorial titled "Writing JUnit tests in NetBeans" and answer the following questions:

  1. What is a TestCase?
  2. What is a TestSuite?
  3. Describe the major differences between JUnit3 and JUnit4 TestCase syntax.
  4. Describe the major differences between JUnit3 and JUnit4 test suite syntax.

Part Two

Use NetBeans to generate TestCase classes for your implementations of Range, DNAFeature, and GeneModel. Check these into the repository. You can use JUnit3 or JUnit4 - your choice!

Edit the classes to include realistic tests, following the model in the tutorial.

If in the course of testing, you discover errors in your code, feel free to fix your code, but document that you did so and report the name of the test method that exposed the error.

Part Three

In Part One, you picked JUnit3 or JUnit4. Now that you have some experience with it, are you happy with your choice? What aspects did you like, not like?