Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.runtime.test.runner
Class RuntimeFeature

java.lang.Object
  extended by org.nuxeo.runtime.test.runner.SimpleFeature
      extended by org.nuxeo.runtime.test.runner.RuntimeFeature
All Implemented Interfaces:
RunnerFeature

public class RuntimeFeature
extends SimpleFeature

Author:
Bogdan Stefanescu

Constructor Summary
RuntimeFeature()
           
 
Method Summary
<T> void
addServiceProvider(Class<T> clazz, com.google.inject.Provider<T> provider)
           
static void bindDatasource(String key, DataSource ds)
           
 void configure(FeaturesRunner runner, com.google.inject.Binder binder)
          Configures Guice bindings if any is required by the feature.
 DeploymentSet deployments()
           
 String[] getDeployments()
           
 RuntimeHarness getHarness()
           
 String[] getLocalDeployments()
           
 void initialize(FeaturesRunner runner)
          Called when preparing to run the test class.
 void start(FeaturesRunner runner)
          Features are initialized.
 void stop(FeaturesRunner runner)
          Before exiting the test.
 
Methods inherited from class org.nuxeo.runtime.test.runner.SimpleFeature
afterMethodRun, afterRun, beforeMethodRun, beforeRun, testCreated
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RuntimeFeature

public RuntimeFeature()
Method Detail

addServiceProvider

public <T> void addServiceProvider(Class<T> clazz,
                                   com.google.inject.Provider<T> provider)

getHarness

public RuntimeHarness getHarness()

deployments

public DeploymentSet deployments()

getDeployments

public String[] getDeployments()

getLocalDeployments

public String[] getLocalDeployments()

initialize

public void initialize(FeaturesRunner runner)
                throws Exception
Description copied from interface: RunnerFeature
Called when preparing to run the test class. Framework is not started at this point. Here is time for the feature to configure the runner from annotations on the test class.

Specified by:
initialize in interface RunnerFeature
Overrides:
initialize in class SimpleFeature
Throws:
Exception

start

public void start(FeaturesRunner runner)
           throws Exception
Description copied from interface: RunnerFeature
Features are initialized. Runner is ready to create the injector.

Specified by:
start in interface RunnerFeature
Overrides:
start in class SimpleFeature
Throws:
Exception

stop

public void stop(FeaturesRunner runner)
          throws Exception
Description copied from interface: RunnerFeature
Before exiting the test.

Specified by:
stop in interface RunnerFeature
Overrides:
stop in class SimpleFeature
Throws:
Exception

configure

public void configure(FeaturesRunner runner,
                      com.google.inject.Binder binder)
Description copied from interface: RunnerFeature
Configures Guice bindings if any is required by the feature. This is called after the framework is started and before Guice module is built. The tests are launched after guice module is built.

Specified by:
configure in interface RunnerFeature
Overrides:
configure in class SimpleFeature

bindDatasource

public static void bindDatasource(String key,
                                  DataSource ds)
                           throws Exception
Throws:
Exception

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.