org.alfresco.bm.tools
Class BMTestRunner

java.lang.Object
  extended by org.alfresco.bm.tools.BMTestRunner

public class BMTestRunner
extends Object

Utility code to assist with starting up a test context to aid development by instantiating a test-only context for execution.

Note that, it is a prerequisite that the alfresco-benchmark-server project is imported as a dependency for this test.

Since:
1.0
Author:
Derek Hulley

Constructor Summary
BMTestRunner(String testAppContextLocation, int threadCount, String mongoUri, String testName, String testRunName, Properties testProperties)
          Construct the help class that will start and stop the test application context
 
Method Summary
 org.springframework.context.support.AbstractApplicationContext getCtx()
           
 void start()
          Start the application context
 void stop()
          Stop the application context
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BMTestRunner

public BMTestRunner(String testAppContextLocation,
                    int threadCount,
                    String mongoUri,
                    String testName,
                    String testRunName,
                    Properties testProperties)
Construct the help class that will start and stop the test application context

Parameters:
testAppContextLocation - the name of the test application context file. This should be based on the testrun-sample-context.xml
threadCount - the number of threads to run
mongoUri - the full MongoDB uri or null to use localhost 'test'
testName - the name of the test e.g. bm_00005
testRunName - the name of the fictitious test run e.g. run_0001
testProperties - additional properties that will be fed into the test context
Method Detail

getCtx

public org.springframework.context.support.AbstractApplicationContext getCtx()
Returns:
Returns the application context whether started or not

start

public void start()
Start the application context


stop

public void stop()
Stop the application context



Copyright © 2012. All Rights Reserved.