| java.lang.Object com.google.gwt.junit.JUnitMessageQueue
JUnitMessageQueue | public class JUnitMessageQueue (Code) | | A message queue to pass data between
JUnitShell and
com.google.gwt.junit.server.JUnitHostImpl in a thread-safe manner.
The public methods are called by the servlet to find out what test to execute
next, and to report the results of the last test to run.
The protected methods are called by the shell to fetch test results and drive
the next test the client should run.
|
Method Summary | |
public String | getNextTestName(String clientId, String testClassName, long timeout) Called by the servlet to query for for the next method to test.
Parameters: testClassName - The name of the test class. Parameters: timeout - How long to wait for an answer. | List<TestResults> | getResults(String testClassName) Fetches the results of a completed test.
Parameters: testClassName - The name of the test class. | boolean | hasResult(String testClassName) Called by the shell to see if the currently-running test has completed.
Parameters: testClassName - The name of the test class. | boolean | haveAllClientsRetrievedCurrentTest() Returns true if all clients have requested the
currently-running test. | public void | reportResults(String testClassName, TestResults results) Called by the servlet to report the results of the last test to run. | void | setNextTestName(String testClassName, String testName) Called by the shell to set the name of the next method to run for this test
class. | void | setNumClients(int numClients) Sets the number of clients that will be executing the JUnit tests in
parallel. |
JUnitMessageQueue | JUnitMessageQueue(int numClients)(Code) | | Only instantiatable within this package.
Parameters: numClients - The number of parallel clients being served by thisqueue. |
getNextTestName | public String getNextTestName(String clientId, String testClassName, long timeout)(Code) | | Called by the servlet to query for for the next method to test.
Parameters: testClassName - The name of the test class. Parameters: timeout - How long to wait for an answer. The next test to run, or null iftimeout is exceeded or the next test does not matchtestClassName . |
getResults | List<TestResults> getResults(String testClassName)(Code) | | Fetches the results of a completed test.
Parameters: testClassName - The name of the test class. An getException thrown from a failed test, or null if the test completed without error. |
hasResult | boolean hasResult(String testClassName)(Code) | | Called by the shell to see if the currently-running test has completed.
Parameters: testClassName - The name of the test class. If the test has completed, true , otherwisefalse . |
haveAllClientsRetrievedCurrentTest | boolean haveAllClientsRetrievedCurrentTest()(Code) | | Returns true if all clients have requested the
currently-running test.
|
reportResults | public void reportResults(String testClassName, TestResults results)(Code) | | Called by the servlet to report the results of the last test to run.
Parameters: testClassName - The name of the test class. Parameters: results - The result of running the test. |
setNextTestName | void setNextTestName(String testClassName, String testName)(Code) | | Called by the shell to set the name of the next method to run for this test
class.
Parameters: testClassName - The name of the test class. Parameters: testName - The name of the method to run. |
setNumClients | void setNumClients(int numClients)(Code) | | Sets the number of clients that will be executing the JUnit tests in
parallel.
Parameters: numClients - must be > 0 |
|
|