org.ogf.graap.wsag.it
Class AbstractIntegrationTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.ogf.graap.wsag.it.WsagTestCase
              extended by org.ogf.graap.wsag.it.AbstractIntegrationTest
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
AbstractAgreementFactoryPersistenceTest, AbstractAgreementFactoryTest, AbstractAgreementNegotiationTest, AbstractAgreementRegistryTest, AbstractNegotiationFactoryTest, AbstractPendingAgreementFactoryTest, AbstractSampleNegotiatorTest

public abstract class AbstractIntegrationTest
extends WsagTestCase

Abstract test case for the WSAG4J framework. This test case uses the WSAG4J client API, but the instantiation of the clients is left to the concrete implementations. Multiple WSRF stack implementations can therefore use the same tests.

Author:
owaeld

Field Summary
static int EXPECTED_TEMPLATES_FACTORY_1
          number of templates at factory 1
static int EXPECTED_TEMPLATES_FACTORY_2
          number of templates at factory 1
 
Constructor Summary
protected AbstractIntegrationTest(String name)
           
 
Method Summary
static AgreementFactoryClient getAgreementFactoryClient(String id)
          Returns the agreement factory test client with the given id.
static AgreementFactoryClient[] getAgreementFactoryClients()
           
 int getDefaultFactoryCount()
          Returns the default number of expected agreement factories at an endpoint.
static LoginContext getLoginContext()
           
static String getUrl()
           
protected  void setUp()
          initializes the agreement factory clients for the test
static void setUrl(String url)
           
protected  void tearDown()
          
 
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

EXPECTED_TEMPLATES_FACTORY_1

public static final int EXPECTED_TEMPLATES_FACTORY_1
number of templates at factory 1

See Also:
Constant Field Values

EXPECTED_TEMPLATES_FACTORY_2

public static final int EXPECTED_TEMPLATES_FACTORY_2
number of templates at factory 1

See Also:
Constant Field Values
Constructor Detail

AbstractIntegrationTest

protected AbstractIntegrationTest(String name)
Parameters:
name - the test name
Method Detail

getUrl

public static String getUrl()
Returns:
the url

setUrl

public static void setUrl(String url)
Parameters:
url - the url to set

setUp

protected void setUp()
              throws Exception
initializes the agreement factory clients for the test

Overrides:
setUp in class WsagTestCase
Throws:
Exception - indicates an error while initializing thefactory clients

tearDown

protected void tearDown()
                 throws Exception

Overrides:
tearDown in class WsagTestCase
Throws:
Exception

getAgreementFactoryClients

public static AgreementFactoryClient[] getAgreementFactoryClients()
Returns:
the agreement factory clients used for testing

getAgreementFactoryClient

public static AgreementFactoryClient getAgreementFactoryClient(String id)
Returns the agreement factory test client with the given id.

Parameters:
id - the factory id
Returns:
the agreement factory client with the given id

getLoginContext

public static LoginContext getLoginContext()
                                    throws Exception
Returns:
the login context
Throws:
Exception - indicates a failure loading the login context (keystore)

getDefaultFactoryCount

public int getDefaultFactoryCount()
Returns the default number of expected agreement factories at an endpoint.

Returns:
the number of expected agreement factories


Copyright © 2008-2012. All Rights Reserved.