org.apache.commons.resources.impl
Class BasicMessageListTestCase

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.apache.commons.resources.impl.BasicMessageListTestCase
All Implemented Interfaces:
junit.framework.Test

public class BasicMessageListTestCase
extends junit.framework.TestCase

Unit tests for the org.apache.commons.resources.MessageList class.

Originally based on org.apache.http.action.TestMessages, Revision 1.4.


Field Summary
protected  org.apache.commons.resources.MessageList aMsgs
           
protected  org.apache.commons.resources.MessageList anMsgs
           
protected  org.apache.commons.resources.Message msg1
           
protected  org.apache.commons.resources.Message msg2
           
protected  org.apache.commons.resources.Message msg3
           
protected  org.apache.commons.resources.Message msg4
           
protected  org.apache.commons.resources.Message msg5
           
protected  org.apache.commons.resources.Message msg6
           
protected  org.apache.commons.resources.Message msg7
           
 
Constructor Summary
BasicMessageListTestCase(String theName)
          Defines the testcase name for JUnit.
 
Method Summary
static void main(String[] theArgs)
          Start the tests.
 void setUp()
           
static junit.framework.Test suite()
           
 void tearDown()
           
 void testAddMessages()
          Tests adding an MessageList object to an MessageList object.
 void testEmpty()
           
 void testGetForAProperty()
           
 void testGetWithNoProperty()
           
 void testGlobalMessageKey()
          Tests using the globalMessageKey on the MessageList object.
 void testNotEmpty()
           
 void testSizeAndEmptyAfterClear()
           
 void testSizeWithManyProperties()
           
 void testSizeWithOneProperty()
           
 
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

aMsgs

protected org.apache.commons.resources.MessageList aMsgs

anMsgs

protected org.apache.commons.resources.MessageList anMsgs

msg1

protected org.apache.commons.resources.Message msg1

msg2

protected org.apache.commons.resources.Message msg2

msg3

protected org.apache.commons.resources.Message msg3

msg4

protected org.apache.commons.resources.Message msg4

msg5

protected org.apache.commons.resources.Message msg5

msg6

protected org.apache.commons.resources.Message msg6

msg7

protected org.apache.commons.resources.Message msg7
Constructor Detail

BasicMessageListTestCase

public BasicMessageListTestCase(String theName)
Defines the testcase name for JUnit.

Parameters:
theName - the testcase's name.
Method Detail

main

public static void main(String[] theArgs)
Start the tests.

Parameters:
theArgs - the arguments. Not used

suite

public static junit.framework.Test suite()
Returns:
a test suite (TestSuite) that includes all methods starting with "test"

setUp

public void setUp()
Overrides:
setUp in class junit.framework.TestCase

tearDown

public void tearDown()
Overrides:
tearDown in class junit.framework.TestCase

testEmpty

public void testEmpty()

testNotEmpty

public void testNotEmpty()

testSizeWithOneProperty

public void testSizeWithOneProperty()

testSizeWithManyProperties

public void testSizeWithManyProperties()

testSizeAndEmptyAfterClear

public void testSizeAndEmptyAfterClear()

testGetWithNoProperty

public void testGetWithNoProperty()

testGetForAProperty

public void testGetForAProperty()

testGlobalMessageKey

public void testGlobalMessageKey()
Tests using the globalMessageKey on the MessageList object.


testAddMessages

public void testAddMessages()
Tests adding an MessageList object to an MessageList object.



Copyright © 2001-2010 The Apache Software Foundation. All Rights Reserved.