de.uds.cs.st.dd.core.test
Class OutcomeCacheTest

java.lang.Object
  |
  +--junit.framework.Assert
        |
        +--junit.framework.TestCase
              |
              +--de.uds.cs.st.dd.core.test.OutcomeCacheTest
All Implemented Interfaces:
junit.framework.Test

public class OutcomeCacheTest
extends junit.framework.TestCase

Test class for the OutcomeCache class. Used for unit testing.

Author:
Philipp Bouillon

Field Summary
static int MAX_ELEMENT_VALUE
           
static int MAX_LIST_LENGTH
           
private  OutcomeCache oc
           
static int STRESS_TEST_CALLS
           
 
Fields inherited from class junit.framework.TestCase
 
Constructor Summary
OutcomeCacheTest(String name)
          Constructor for OutcomeCacheTest.
 
Method Summary
protected  void setUp()
          Creates a new OutcomeCache object for testing purposes.
protected  void tearDown()
          Sets the reference of the cache to null.
 void testAdd()
          Tests the method OutcomeCache.add.
 void testAddSorted()
          Tests the method OutcomeCache.addSorted.
 void testLookupSubset()
          Tests the method OutcomeCache.lookupSubset.
 void testLookupSuperset()
          Tests the method OutcomeCache.lookupSuperset.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MAX_ELEMENT_VALUE

public static final int MAX_ELEMENT_VALUE
See Also:
Constant Field Values

MAX_LIST_LENGTH

public static final int MAX_LIST_LENGTH
See Also:
Constant Field Values

STRESS_TEST_CALLS

public static final int STRESS_TEST_CALLS
See Also:
Constant Field Values

oc

private OutcomeCache oc
Constructor Detail

OutcomeCacheTest

public OutcomeCacheTest(String name)
Constructor for OutcomeCacheTest.

Parameters:
name - the name of this test.
Method Detail

setUp

protected void setUp()
              throws Exception
Creates a new OutcomeCache object for testing purposes.

Overrides:
setUp in class junit.framework.TestCase
Exception
See Also:
TestCase.setUp()

tearDown

protected void tearDown()
                 throws Exception
Sets the reference of the cache to null.

Overrides:
tearDown in class junit.framework.TestCase
Exception
See Also:
TestCase.tearDown()

testAdd

public void testAdd()
Tests the method OutcomeCache.add.


testAddSorted

public void testAddSorted()
Tests the method OutcomeCache.addSorted.


testLookupSubset

public void testLookupSubset()
Tests the method OutcomeCache.lookupSubset.


testLookupSuperset

public void testLookupSuperset()
Tests the method OutcomeCache.lookupSuperset.