edu.sdsc.inca.protocol
Class MessageHandlerFactoryTest

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended byedu.sdsc.inca.protocol.MessageHandlerFactoryTest
All Implemented Interfaces:
junit.framework.Test

public class MessageHandlerFactoryTest
extends junit.framework.TestCase

Author:
Cathie Olschanowski, Jim Hayes

Constructor Summary
MessageHandlerFactoryTest()
           
 
Method Summary
 void setUp()
           
 void testCRLFOnly()
          If the stream only contains CRLF then there should be a protocol exception.
 void testEmptyStream()
          Test the empty stream case.
 void testIncompleteStatement()
          Incomplete statement is a protocol exception.
 void testStart()
          Test instantiating the START command.
 void testUnknownCommand()
          Unknown command is a protocol exception.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, tearDown, 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
 

Constructor Detail

MessageHandlerFactoryTest

public MessageHandlerFactoryTest()
Method Detail

setUp

public void setUp()
           throws java.lang.Exception
Throws:
java.lang.Exception

testStart

public void testStart()
               throws java.lang.ClassNotFoundException,
                      java.lang.IllegalAccessException,
                      java.lang.InstantiationException,
                      java.io.IOException,
                      ProtocolException
Test instantiating the START command.

Throws:
java.lang.ClassNotFoundException
java.lang.IllegalAccessException
java.lang.InstantiationException
java.io.IOException
ProtocolException

testEmptyStream

public void testEmptyStream()
Test the empty stream case. In this case null should be returned indicating that the end of the stream has been reached


testCRLFOnly

public void testCRLFOnly()
If the stream only contains CRLF then there should be a protocol exception.


testIncompleteStatement

public void testIncompleteStatement()
Incomplete statement is a protocol exception.


testUnknownCommand

public void testUnknownCommand()
Unknown command is a protocol exception.