org.qi4j.test
Class AbstractQi4jScenarioTest

java.lang.Object
  extended by org.qi4j.test.AbstractQi4jScenarioTest
All Implemented Interfaces:
Assembler

public abstract class AbstractQi4jScenarioTest
extends java.lang.Object
implements Assembler

Base class for Qi4j scenario tests. This will create one Qi4j application per class instead of per test.


Field Summary
protected static Qi4j api
           
protected static Application application
           
protected static ApplicationDescriptor applicationModel
           
protected static Assembler assembler
           
protected static Module module
           
protected static Energy4Java qi4j
           
protected static Qi4jSPI spi
           
 
Constructor Summary
AbstractQi4jScenarioTest()
           
 
Method Summary
protected static void assemblyException(AssemblyException exception)
          This method is called when there was an AssemblyException in the creation of the Qi4j application model.
protected  org.slf4j.Logger getLog()
           
protected static void initApplication(Application app)
           
protected static ApplicationDescriptor newApplication()
           
static void setUp()
           
 void tearDown()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.qi4j.bootstrap.Assembler
assemble
 

Field Detail

api

protected static Qi4j api

spi

protected static Qi4jSPI spi

qi4j

protected static Energy4Java qi4j

applicationModel

protected static ApplicationDescriptor applicationModel

application

protected static Application application

module

protected static Module module

assembler

protected static Assembler assembler
Constructor Detail

AbstractQi4jScenarioTest

public AbstractQi4jScenarioTest()
Method Detail

setUp

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

newApplication

protected static ApplicationDescriptor newApplication()
                                               throws AssemblyException
Throws:
AssemblyException

assemblyException

protected static void assemblyException(AssemblyException exception)
                                 throws AssemblyException
This method is called when there was an AssemblyException in the creation of the Qi4j application model.

Override this method to catch valid failures to place into satisfiedBy suites.

Parameters:
exception - the exception thrown.
Throws:
AssemblyException - The default implementation of this method will simply re-throw the exception.

initApplication

protected static void initApplication(Application app)
                               throws java.lang.Exception
Throws:
java.lang.Exception

tearDown

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

getLog

protected org.slf4j.Logger getLog()