vgrid.test
Class AbstractServerTestCase

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by vgrid.test.AbstractServerTestCase
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
FileServerTestCase, InMemoryServerTestCase

public abstract class AbstractServerTestCase
extends junit.framework.TestCase

Contains the server testcases in a form where the actual implementaions of Server are not defined. See subclasses.


Constructor Summary
AbstractServerTestCase(java.lang.String testName)
           
 
Method Summary
protected  void add1ExceptionTestTask(ExecutingPlodderServer srv)
           
protected  void add5TestTasks(ExecutingPlodderServer srv)
           
protected  void assertEqualsStrings(java.util.Collection c, java.lang.String str0, java.lang.String str1)
           
protected  void assertEqualsUrls(java.util.Collection c, java.lang.String str0, java.lang.String str1)
           
protected  void assertFinished(ExecutingPlodderServer srv, java.lang.String id)
           
protected  void assertNotFinished(ExecutingPlodderServer srv, java.lang.String id)
           
protected  void assertServerHasNoLibs(ExecutingPlodderServer srv)
           
protected  void assertUrlIsAccessable(java.lang.String urlString)
           
protected  TaskState getTaskState(ExecutingPlodderServer srv, java.lang.String id)
           
protected  java.io.InputStream getTestLibraryInputStream(java.lang.String resource)
           
protected  java.lang.String readInputStream(java.io.InputStream in)
           
protected  void removeAllLibsFromServer(ExecutingPlodderServer srv)
           
protected  void removeAllTasks(ExecutingPlodderServer srv)
           
protected  void removeAllTasks(ExecutingPlodderServer srv, TaskState state)
           
protected  java.io.InputStream serialize(Task t)
           
protected  void testDeleteFinished(ExecutingPlodderServer srv)
           
protected  void testInit(ExecutingPlodderServer srv)
           
protected  void testIsFinished(ExecutingPlodderServer srv)
           
protected  void testLib(ExecutingPlodderServer srv, java.lang.String url1, java.lang.String url2)
           
protected  void testReceiveUnfinished(ExecutingPlodderServer srv)
           
protected  void testRequestOne(ExecutingPlodderServer srv)
           
protected  void testRunOneErrorTask(ExecutingPlodderServer srv)
           
protected  void testSendFinished(ExecutingPlodderServer srv)
           
protected  void testTaskState(ExecutingPlodderServer srv)
           
protected  void testTaskStateError(ExecutingPlodderServer srv)
           
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, 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

AbstractServerTestCase

public AbstractServerTestCase(java.lang.String testName)
Method Detail

readInputStream

protected java.lang.String readInputStream(java.io.InputStream in)
                                    throws java.io.IOException
Throws:
java.io.IOException

assertFinished

protected void assertFinished(ExecutingPlodderServer srv,
                              java.lang.String id)
                       throws VgridException
Throws:
VgridException

assertNotFinished

protected void assertNotFinished(ExecutingPlodderServer srv,
                                 java.lang.String id)
                          throws VgridException
Throws:
VgridException

serialize

protected java.io.InputStream serialize(Task t)
                                 throws VgridException
Throws:
VgridException

getTaskState

protected TaskState getTaskState(ExecutingPlodderServer srv,
                                 java.lang.String id)
                          throws VgridException
Throws:
VgridException

add5TestTasks

protected void add5TestTasks(ExecutingPlodderServer srv)
                      throws VgridException
Throws:
VgridException

add1ExceptionTestTask

protected void add1ExceptionTestTask(ExecutingPlodderServer srv)
                              throws VgridException
Throws:
VgridException

testInit

protected void testInit(ExecutingPlodderServer srv)
                 throws VgridException
Throws:
VgridException

testRequestOne

protected void testRequestOne(ExecutingPlodderServer srv)
                       throws VgridException,
                              java.io.IOException
Throws:
VgridException
java.io.IOException

testRunOneErrorTask

protected void testRunOneErrorTask(ExecutingPlodderServer srv)
                            throws java.lang.Exception
Throws:
java.lang.Exception

testReceiveUnfinished

protected void testReceiveUnfinished(ExecutingPlodderServer srv)
                              throws java.lang.Exception
Throws:
java.lang.Exception

testIsFinished

protected void testIsFinished(ExecutingPlodderServer srv)
                       throws VgridException
Throws:
VgridException

testDeleteFinished

protected void testDeleteFinished(ExecutingPlodderServer srv)
                           throws VgridException
Throws:
VgridException

testTaskState

protected void testTaskState(ExecutingPlodderServer srv)
                      throws java.lang.Exception
Throws:
java.lang.Exception

testTaskStateError

protected void testTaskStateError(ExecutingPlodderServer srv)
                           throws java.lang.Exception
Throws:
java.lang.Exception

testSendFinished

protected void testSendFinished(ExecutingPlodderServer srv)
                         throws VgridException
Throws:
VgridException

removeAllTasks

protected void removeAllTasks(ExecutingPlodderServer srv)
                       throws VgridException
Throws:
VgridException

removeAllTasks

protected void removeAllTasks(ExecutingPlodderServer srv,
                              TaskState state)
                       throws VgridException
Throws:
VgridException

getTestLibraryInputStream

protected java.io.InputStream getTestLibraryInputStream(java.lang.String resource)
                                                 throws java.io.IOException
Throws:
java.io.IOException

removeAllLibsFromServer

protected void removeAllLibsFromServer(ExecutingPlodderServer srv)
                                throws VgridException
Throws:
VgridException

assertServerHasNoLibs

protected void assertServerHasNoLibs(ExecutingPlodderServer srv)
                              throws VgridException
Throws:
VgridException

assertEqualsUrls

protected void assertEqualsUrls(java.util.Collection c,
                                java.lang.String str0,
                                java.lang.String str1)

assertEqualsStrings

protected void assertEqualsStrings(java.util.Collection c,
                                   java.lang.String str0,
                                   java.lang.String str1)

assertUrlIsAccessable

protected void assertUrlIsAccessable(java.lang.String urlString)
                              throws java.io.IOException,
                                     java.net.MalformedURLException
Throws:
java.io.IOException
java.net.MalformedURLException

testLib

protected void testLib(ExecutingPlodderServer srv,
                       java.lang.String url1,
                       java.lang.String url2)
                throws VgridException,
                       java.io.IOException,
                       java.net.MalformedURLException
Throws:
VgridException
java.io.IOException
java.net.MalformedURLException


vgrid the vienna grid project