Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2344)

Unified Diff: net/test/local_test_server.h

Issue 12033057: Make PPAPI test servers start in parallel (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Make RemoteTestServer compile Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/ppapi/ppapi_test.cc ('k') | net/test/local_test_server.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/test/local_test_server.h
diff --git a/net/test/local_test_server.h b/net/test/local_test_server.h
index 3c6bddec38753183d47dac181e006d82b35ddb57..8ded2957af6650c84b6e02646139cce30d0a3b5f 100644
--- a/net/test/local_test_server.h
+++ b/net/test/local_test_server.h
@@ -37,8 +37,30 @@ class LocalTestServer : public BaseTestServer {
virtual ~LocalTestServer();
+ // Start the test server and block until it's ready. Returns true on success,
+ // false on failure.
Paweł Hajdan Jr. 2013/01/24 19:31:57 nit: "false on failure" is redundant, please remov
bool Start() WARN_UNUSED_RESULT;
+ // Start the test server without blocking. Use this if you need multiple test
+ // servers (such as WebSockets and HTTP, or HTTP and HTTPS). You must call
+ // BlockUntilStarted on all servers your test requires before executing the
+ // test. For example:
+ //
+ // // Start the servers in parallel.
+ // ASSERT_TRUE(http_server.StartInBackground());
+ // ASSERT_TRUE(websocket_server.StartInBackground());
+ // // Wait for both servers to be ready.
+ // ASSERT_TRUE(http_server.BlockUntilStarted());
+ // ASSERT_TRUE(websocket_server.BlockUntilStarted());
+ // RunMyTest();
+ //
+ // Returns true on success, false on failure.
Paweł Hajdan Jr. 2013/01/24 19:31:57 nit: "false on failure" is redundant, please remov
+ bool StartInBackground() WARN_UNUSED_RESULT;
+
+ // Block until ths test server is ready. Returns true on success, false on
Paweł Hajdan Jr. 2013/01/24 19:31:57 nit: "false on failure" is redundant, please remov
+ // failure. Block See StartInBackground() documentation for more information.
+ bool BlockUntilStarted() WARN_UNUSED_RESULT;
+
// Stop the server started by Start().
bool Stop();
« no previous file with comments | « chrome/test/ppapi/ppapi_test.cc ('k') | net/test/local_test_server.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698