# HG changeset patch # User dadubrow # Date 1277498696 18000 # Node ID 3eb6c57e65c0d5da94abed5668e23abda7a23119 # Parent 93a010393cd960725fc73ae713e26c821dffbbda Bug 11222 diff -r 93a010393cd9 -r 3eb6c57e65c0 connectivity/com.nokia.carbide.remoteConnections.tests/src/com/nokia/carbide/remoteconnections/tests/discovery/RandomDiscoveryAgent.java --- a/connectivity/com.nokia.carbide.remoteConnections.tests/src/com/nokia/carbide/remoteconnections/tests/discovery/RandomDiscoveryAgent.java Fri Jun 25 15:35:46 2010 -0500 +++ b/connectivity/com.nokia.carbide.remoteConnections.tests/src/com/nokia/carbide/remoteconnections/tests/discovery/RandomDiscoveryAgent.java Fri Jun 25 15:44:56 2010 -0500 @@ -101,7 +101,7 @@ } } - private DiscoveryThread thread = new DiscoveryThread(); + private DiscoveryThread thread; public URL getInformation() { return null; @@ -131,20 +131,33 @@ } public void start() throws CoreException { - if (TestFilter.isTest) + if (TestFilter.isTest) { + thread = new DiscoveryThread(); thread.start(); + } } public void stop() throws CoreException { - thread.stopRunning(); + if (TestFilter.isTest) { + thread.stopRunning(); + thread = null; + } } public String getDisplayName() { - return "Random Test Discovery Agent"; + return "Random Test Discovery"; } public IPrerequisiteStatus getPrerequisiteStatus() { return (new RandomPrerequisiteStatus()); } + public boolean isRunning() { + return thread != null; + } + + public String getId() { + return getClass().getName(); + } + }