Random cleanup I had kicking around
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5818 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -30,7 +30,7 @@ import com.threerings.bureau.data.AgentObject;
|
||||
import static com.threerings.bureau.Log.log;
|
||||
|
||||
/**
|
||||
* Extends bureau client minimally and provides a static main function to create a client and
|
||||
* Extends bureau client minimally and provides a static main function to create a client and
|
||||
* connect to a server given by system properties.
|
||||
*/
|
||||
public class TestClient extends BureauClient
|
||||
@@ -43,10 +43,10 @@ public class TestClient extends BureauClient
|
||||
|
||||
// create the client and log on
|
||||
TestClient client = new TestClient(
|
||||
System.getProperty("token"),
|
||||
System.getProperty("token"),
|
||||
System.getProperty("bureauId"));
|
||||
client.setServer(
|
||||
System.getProperty("serverName"),
|
||||
System.getProperty("serverName"),
|
||||
new int[] {Integer.parseInt(System.getProperty("serverPort"))});
|
||||
client.logon();
|
||||
|
||||
@@ -81,7 +81,7 @@ public class TestClient extends BureauClient
|
||||
@Override
|
||||
protected BureauDirector createDirector ()
|
||||
{
|
||||
// just use our test agent exclusively - in the real world, the agent created would depend
|
||||
// just use our test agent exclusively - in the real world, the agent created would depend
|
||||
// on the object's type and/or properties
|
||||
return new BureauDirector(_ctx) {
|
||||
@Override public Agent createAgent (AgentObject agentObj) {
|
||||
|
||||
@@ -42,7 +42,7 @@ import static com.threerings.bureau.Log.log;
|
||||
|
||||
/**
|
||||
* Uses a TestServer to pound on the BureauRegistry. Sends random sequences of
|
||||
* startAgent and destroyAgent. Most aspects of the randomness are configurable using system
|
||||
* startAgent and destroyAgent. Most aspects of the randomness are configurable using system
|
||||
* properties.
|
||||
* TODO: add more types of testing
|
||||
* TODO: allow a quitAfter configuration parameter to shut down automatically
|
||||
@@ -138,7 +138,7 @@ public class RegistryTester
|
||||
{
|
||||
_stop = true;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The main loop for the tests.
|
||||
*/
|
||||
@@ -283,7 +283,7 @@ public class RegistryTester
|
||||
|
||||
// maximum number of agents to keep around
|
||||
protected int _maxAgents;
|
||||
|
||||
|
||||
// number of bureaus to select between
|
||||
protected int _numBureaus;
|
||||
|
||||
@@ -301,7 +301,7 @@ public class RegistryTester
|
||||
|
||||
// maximum delay between batches of requests
|
||||
protected int _maxDelay;
|
||||
|
||||
|
||||
// ant target to use to kick off new bureaus
|
||||
protected String _clientTarget;
|
||||
}
|
||||
|
||||
@@ -131,7 +131,7 @@ public class TestClient
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
public Client getClient ()
|
||||
{
|
||||
return _client;
|
||||
|
||||
Reference in New Issue
Block a user