JUnit >>
<< Eclipse Configuration:
When you have a c…

Author Zhou Renjian Create@ 2004-02-22 14:38
whizz Note icon

When you have a common fixture, here is what you do:

  1. Create a subclass of TestCase
  2. Create a constructor which accepts a String as a parameter and passes it to the superclass.
  3. Add an instance variable for each part of the fixture
  4. Override setUp() to initialize the variables
  5. Override tearDown() to release any permanent resources you allocated in setUp
本记录所在类别:
本记录相关记录: