0 Replies Latest reply on Jul 25, 2007 2:47 AM by Ales Justin

    Writing Tests instructions

    Ales Justin Master


      "adrian@jboss.org" wrote:

      1) MicrocontainerTest is not a part of the testsuite it is a part of the Microcontainer that can be consumed by others. There should be only one MicrocontainerTest class, extends MicrocontainerTest should be in the testsuite.

      2) The MicrocontainerTestDelegate is the place to parameterize tests not subclassing. All relevant features should be in this class.

      3) You shouldn't have to access the delegate to do reasonable operations.

      4) Tests should not fix problems in the main code by subclassing.

      5) All tests should be run with a security manager enabled. The easiest way to do this is to always extend an Abstract class specific to those tests that enable the security manager on the test delegate.This Abstract class is also a good place to put common helpers for related tests.