Package org.testng.remote.strprotocol
Class AbstractRemoteTestRunnerClient
- java.lang.Object
-
- org.testng.remote.strprotocol.AbstractRemoteTestRunnerClient
-
public abstract class AbstractRemoteTestRunnerClient extends java.lang.Object
The client side of the RemoteTestRunner. Handles the marshaling of the different messages.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
AbstractRemoteTestRunnerClient.ServerConnection
Reads the message stream from the RemoteTestRunner
-
Field Summary
Fields Modifier and Type Field Description private java.net.ServerSocket
fServerSocket
The server socketprivate java.net.Socket
fSocket
private AbstractRemoteTestRunnerClient.ServerConnection
m_serverConnection
protected IRemoteSuiteListener[]
m_suiteListeners
An array of listeners that are informed about test events.protected IRemoteTestListener[]
m_testListeners
-
Constructor Summary
Constructors Constructor Description AbstractRemoteTestRunnerClient()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description IRemoteSuiteListener[]
getSuiteListeners()
IRemoteTestListener[]
getTestListeners()
boolean
isRunning()
protected abstract void
notifyResultEvents(TestResultMessage testResultMessage)
protected abstract void
notifyStart(GenericMessage genericMessage)
protected abstract void
notifySuiteEvents(SuiteMessage suiteMessage)
protected abstract void
notifyTestEvents(TestMessage testMessage)
private void
shutdown()
void
startListening(IRemoteSuiteListener[] suiteListeners, IRemoteTestListener[] testListeners, AbstractRemoteTestRunnerClient.ServerConnection serverConnection)
Start listening to a test run.void
stopTest()
Requests to stop the remote test run.
-
-
-
Field Detail
-
m_suiteListeners
protected IRemoteSuiteListener[] m_suiteListeners
An array of listeners that are informed about test events.
-
m_testListeners
protected IRemoteTestListener[] m_testListeners
-
fServerSocket
private java.net.ServerSocket fServerSocket
The server socket
-
fSocket
private java.net.Socket fSocket
-
m_serverConnection
private AbstractRemoteTestRunnerClient.ServerConnection m_serverConnection
-
-
Method Detail
-
startListening
public void startListening(IRemoteSuiteListener[] suiteListeners, IRemoteTestListener[] testListeners, AbstractRemoteTestRunnerClient.ServerConnection serverConnection)
Start listening to a test run. Start a server connection that the RemoteTestRunner can connect to.
-
getSuiteListeners
public IRemoteSuiteListener[] getSuiteListeners()
-
getTestListeners
public IRemoteTestListener[] getTestListeners()
-
shutdown
private void shutdown()
-
isRunning
public boolean isRunning()
-
stopTest
public void stopTest()
Requests to stop the remote test run.
-
notifyStart
protected abstract void notifyStart(GenericMessage genericMessage)
-
notifySuiteEvents
protected abstract void notifySuiteEvents(SuiteMessage suiteMessage)
-
notifyTestEvents
protected abstract void notifyTestEvents(TestMessage testMessage)
-
notifyResultEvents
protected abstract void notifyResultEvents(TestResultMessage testResultMessage)
-
-