com.eviware.soapui.impl.wsdl.panels.support
Class AbstractMockTestRunner<T extends TestRunnable>

java.lang.Object
  extended by com.eviware.soapui.impl.wsdl.panels.support.AbstractMockTestRunner<T>
All Implemented Interfaces:
TestRunner
Direct Known Subclasses:
MockLoadTestRunner, MockProjectRunner, MockTestRunner, MockTestSuiteRunner

public abstract class AbstractMockTestRunner<T extends TestRunnable>
extends java.lang.Object
implements TestRunner

Dummy TestRunner used when executing TestSteps one by one

Author:
ole.matzura

Nested Class Summary
 
Nested classes/interfaces inherited from interface com.eviware.soapui.model.testsuite.TestRunner
TestRunner.Status
 
Constructor Summary
AbstractMockTestRunner(T modelItem, org.apache.log4j.Logger logger)
           
 
Method Summary
 void cancel(java.lang.String reason)
          Cancels an ongoing test run with the specified reason
 void fail(java.lang.String reason)
          Fails an ongoing test run with the specified reason
 org.apache.log4j.Logger getLog()
           
 java.lang.String getReason()
          Gets the reason why a running test was canceled or failed.
 TestRunContext getRunContext()
           
 long getStartTime()
          Returns the time this runner was last started
 TestRunner.Status getStatus()
          Gets the current status of this TestRunner
 T getTestRunnable()
           
 long getTimeTaken()
          Returns the time taken by this runner since its last start
 void setRunContext(TestRunContext context)
           
 void start(boolean async)
          Starts running this TestRunners TestCase.
 TestRunner.Status waitUntilFinished()
          Blocks until this runner is finished, (returns directly if it already has finished)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractMockTestRunner

public AbstractMockTestRunner(T modelItem,
                              org.apache.log4j.Logger logger)
Method Detail

setRunContext

public void setRunContext(TestRunContext context)

getRunContext

public TestRunContext getRunContext()
Specified by:
getRunContext in interface TestRunner

getLog

public org.apache.log4j.Logger getLog()

getTestRunnable

public T getTestRunnable()
Specified by:
getTestRunnable in interface TestRunner

getStatus

public TestRunner.Status getStatus()
Description copied from interface: TestRunner
Gets the current status of this TestRunner

Specified by:
getStatus in interface TestRunner

start

public void start(boolean async)
Description copied from interface: TestRunner
Starts running this TestRunners TestCase. If the async flag is set to true, this method will return directly, otherwise it will block until the TestCase is finished

Specified by:
start in interface TestRunner
Parameters:
async - flag controlling if TestCase should be run in seperate or callers thread.

getTimeTaken

public long getTimeTaken()
Description copied from interface: TestRunner
Returns the time taken by this runner since its last start

Specified by:
getTimeTaken in interface TestRunner

waitUntilFinished

public TestRunner.Status waitUntilFinished()
Description copied from interface: TestRunner
Blocks until this runner is finished, (returns directly if it already has finished)

Specified by:
waitUntilFinished in interface TestRunner

cancel

public void cancel(java.lang.String reason)
Description copied from interface: TestRunner
Cancels an ongoing test run with the specified reason

Specified by:
cancel in interface TestRunner

fail

public void fail(java.lang.String reason)
Description copied from interface: TestRunner
Fails an ongoing test run with the specified reason

Specified by:
fail in interface TestRunner

getStartTime

public long getStartTime()
Description copied from interface: TestRunner
Returns the time this runner was last started

Specified by:
getStartTime in interface TestRunner

getReason

public java.lang.String getReason()
Description copied from interface: TestRunner
Gets the reason why a running test was canceled or failed.

Specified by:
getReason in interface TestRunner


Copyright © 2005-2010 eviware.com. All Rights Reserved.