Class ChainBaseTestCase

java.lang.Object
org.apache.commons.chain.impl.ChainBaseTestCase

public class ChainBaseTestCase extends Object
Test case for the ChainBase class.
Version:
$Revision$ $Date$
Author:
Craig R. McClanahan
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected Chain<Context>
    The Chain instance under test.
    protected Context
    The Context instance on which to execute the chain.
  • Constructor Summary

    Constructors
    Constructor
    Description
    The Default-Constructor for this class.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    checkCommandCount(int expected)
    Verify the number of configured commands
    protected void
    Verify the contents of the execution log
    void
    Set up instance variables required by this test case.
    void
    Tear down instance variables required by this test case.
    void
    Test the ability to add commands
    void
    Test execution of a single non-delegating command
    void
    Test execution of a single delegating command
    void
    Test execution of a single exception-throwing command
    void
    Test execution of an attempt to add a new Command while executing
    void
    Test execution of a chain that should return true
    void
    Test execution of a chain that should return false
    void
    Test execution of a chain that should throw an exception
    void
    Test execution of a chain that should throw an exception in the middle
    void
    Test execution of a single non-delegating filter
    void
    Test execution of a single delegating filter
    void
    Test execution of a single exception-throwing filter
    void
    Test execution of a chain that should return true
    void
    Test execution of a chain that should return false
    void
    Test execution of a chain that should throw an exception
    void
    Test execution of a chain that should throw an exception in the middle
    void
    Test state of newly created instance

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • ChainBaseTestCase

      The Default-Constructor for this class.
  • Method Details

    • init

      @BeforeEach public void init()
      Set up instance variables required by this test case.
    • tearDown

      @AfterEach public void tearDown()
      Tear down instance variables required by this test case.
    • testCommands

      @Test public void testCommands()
      Test the ability to add commands
    • testExecute1a

      @Test public void testExecute1a()
      Test execution of a single non-delegating command
    • testExecute1b

      @Test public void testExecute1b()
      Test execution of a single delegating command
    • testExecute1c

      @Test public void testExecute1c()
      Test execution of a single exception-throwing command
    • testExecute1d

      @Test public void testExecute1d()
      Test execution of an attempt to add a new Command while executing
    • testExecute2a

      @Test public void testExecute2a()
      Test execution of a chain that should return true
    • testExecute2b

      @Test public void testExecute2b()
      Test execution of a chain that should return false
    • testExecute2c

      @Test public void testExecute2c()
      Test execution of a chain that should throw an exception
    • testExecute2d

      @Test public void testExecute2d()
      Test execution of a chain that should throw an exception in the middle
    • testExecute3a

      @Test public void testExecute3a()
      Test execution of a single non-delegating filter
    • testExecute3b

      @Test public void testExecute3b()
      Test execution of a single delegating filter
    • testExecute3c

      @Test public void testExecute3c()
      Test execution of a single exception-throwing filter
    • testExecute4a

      @Test public void testExecute4a()
      Test execution of a chain that should return true
    • testExecute4b

      @Test public void testExecute4b()
      Test execution of a chain that should return false
    • testExecute4c

      @Test public void testExecute4c()
      Test execution of a chain that should throw an exception
    • testExecute4d

      @Test public void testExecute4d()
      Test execution of a chain that should throw an exception in the middle
    • testNewInstance

      @Test public void testNewInstance()
      Test state of newly created instance
    • checkCommandCount

      protected void checkCommandCount(int expected)
      Verify the number of configured commands
      Parameters:
      expected - the expected value
    • checkExecuteLog

      protected void checkExecuteLog(String expected)
      Verify the contents of the execution log
      Parameters:
      expected - the expected value