Published at: 09:04 pm - Sunday April 03 2011
One important feature of any test framework is setting up a test fixture and tearing it down afterwards. In JUnit 3 for you did that by overriding the methods setup() and teardown() of the class TestCase, which every test needed to extend. JUnit 4 was a little more flexible. The name of the methods was [...]
Published at: 06:07 am - Sunday July 18 2010
Question: what are the properties which make a test a good unit test? If you have a good answer, check out my answer and add to it in the comments. If you don’t here is mine. Long Descriptive Name: For example returnsNullWhenCalledOnEmptyList is a nice name for a test Simple Clean Structure: A test performs [...]