org.jboss.osgi.testing
Class OSGiTest

java.lang.Object
  extended by org.jboss.osgi.testing.OSGiTest
Direct Known Subclasses:
OSGiFrameworkTest, OSGiRuntimeTest

public abstract class OSGiTest
extends Object

An abstract OSGi Test. A convenience wrapper for the functionality provided by OSGiTestHelper.

Since:
25-Sep-2008
Author:
Thomas.Diesler@jboss.org

Constructor Summary
OSGiTest()
           
 
Method Summary
protected  org.jboss.shrinkwrap.api.spec.JavaArchive assembleArchive(String name, String[] resources, Class<?>... packages)
          Delegates to OSGiTestHelper.assembleArchive(String, String[], Class...)
protected  org.jboss.shrinkwrap.api.spec.JavaArchive assembleArchive(String name, String resource, Class<?>... packages)
          Delegates to OSGiTestHelper.assembleArchive(String, String, Class...)
protected  void assertBundleState(int expState, int wasState)
          Delegates to OSGiTestHelper.assertBundleState(int, int)
protected  Class<?> assertLoadClass(Bundle bundle, String className)
          Delegates to OSGiTestHelper.assertLoadClass(Bundle, String)
protected  void assertLoadClass(Bundle bundle, String className, Bundle exporter)
          Delegates to OSGiTestHelper.assertLoadClass(Bundle, String, Bundle)
protected  void assertLoadClassFail(Bundle bundle, String className)
          Delegates to OSGiTestHelper.assertLoadClassFail(Bundle, String)
protected  String getFrameworkName()
          Delegates to OSGiTestHelper.getFrameworkName()
protected  String getLongName()
          Get the the FQN of this test class.
protected  File getResourceFile(String resource)
          Delegates to OSGiTestHelper.getResourceFile(String)
protected  URL getResourceURL(String resource)
          Delegates to OSGiTestHelper.getResourceURL(String)
protected  String getServerHost()
          Delegates to OSGiTestHelper.getServerHost()
protected  String getShortName()
          Get the last token in the FQN of this test class.
protected  String getTargetContainer()
          Delegates to OSGiTestHelper.getTargetContainer()
protected  File getTestArchiveFile(String archive)
          Delegates to OSGiTestHelper.getTestArchiveFile(String)
protected  String getTestArchivePath(String archive)
          Delegates to OSGiTestHelper.getTestArchivePath(String)
protected  URL getTestArchiveURL(String archive)
          Delegates to OSGiTestHelper.getTestArchiveURL(String)
 void setUp()
          Writes a a debug start messge
 void tearDown()
          Writes a a debug stop messge
protected  InputStream toInputStream(org.jboss.shrinkwrap.api.Archive<?> archive)
          Delegates to OSGiTestHelper.toInputStream(Archive)
protected  VirtualFile toVirtualFile(org.jboss.shrinkwrap.api.Archive<?> archive)
          Delegates to OSGiTestHelper.toVirtualFile(Archive)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OSGiTest

public OSGiTest()
Method Detail

setUp

public void setUp()
           throws Exception
Writes a a debug start messge

Throws:
Exception

tearDown

public void tearDown()
              throws Exception
Writes a a debug stop messge

Throws:
Exception

getShortName

protected String getShortName()
Get the last token in the FQN of this test class.


getLongName

protected String getLongName()
Get the the FQN of this test class.


getResourceURL

protected URL getResourceURL(String resource)
Delegates to OSGiTestHelper.getResourceURL(String)


getResourceFile

protected File getResourceFile(String resource)
Delegates to OSGiTestHelper.getResourceFile(String)


getTestArchiveURL

protected URL getTestArchiveURL(String archive)
Delegates to OSGiTestHelper.getTestArchiveURL(String)


getTestArchivePath

protected String getTestArchivePath(String archive)
Delegates to OSGiTestHelper.getTestArchivePath(String)


getTestArchiveFile

protected File getTestArchiveFile(String archive)
Delegates to OSGiTestHelper.getTestArchiveFile(String)


getServerHost

protected String getServerHost()
Delegates to OSGiTestHelper.getServerHost()


getTargetContainer

protected String getTargetContainer()
Delegates to OSGiTestHelper.getTargetContainer()


getFrameworkName

protected String getFrameworkName()
Delegates to OSGiTestHelper.getFrameworkName()


assembleArchive

protected org.jboss.shrinkwrap.api.spec.JavaArchive assembleArchive(String name,
                                                                    String resource,
                                                                    Class<?>... packages)
                                                             throws Exception
Delegates to OSGiTestHelper.assembleArchive(String, String, Class...)

Throws:
Exception

assembleArchive

protected org.jboss.shrinkwrap.api.spec.JavaArchive assembleArchive(String name,
                                                                    String[] resources,
                                                                    Class<?>... packages)
                                                             throws Exception
Delegates to OSGiTestHelper.assembleArchive(String, String[], Class...)

Throws:
Exception

toVirtualFile

protected VirtualFile toVirtualFile(org.jboss.shrinkwrap.api.Archive<?> archive)
                             throws IOException,
                                    MalformedURLException
Delegates to OSGiTestHelper.toVirtualFile(Archive)

Throws:
IOException
MalformedURLException

toInputStream

protected InputStream toInputStream(org.jboss.shrinkwrap.api.Archive<?> archive)
                             throws IOException,
                                    MalformedURLException
Delegates to OSGiTestHelper.toInputStream(Archive)

Throws:
IOException
MalformedURLException

assertBundleState

protected void assertBundleState(int expState,
                                 int wasState)
Delegates to OSGiTestHelper.assertBundleState(int, int)


assertLoadClass

protected Class<?> assertLoadClass(Bundle bundle,
                                   String className)
Delegates to OSGiTestHelper.assertLoadClass(Bundle, String)


assertLoadClassFail

protected void assertLoadClassFail(Bundle bundle,
                                   String className)
Delegates to OSGiTestHelper.assertLoadClassFail(Bundle, String)


assertLoadClass

protected void assertLoadClass(Bundle bundle,
                               String className,
                               Bundle exporter)
Delegates to OSGiTestHelper.assertLoadClass(Bundle, String, Bundle)



Copyright © 2011. All Rights Reserved.