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

Unified Diff: chrome/test/ui_test_utils.h

Issue 6042009: Added WARN_UNUSED_RESULT to ScopedTempDir methods. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Whitespace fix Created 9 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
Index: chrome/test/ui_test_utils.h
diff --git a/chrome/test/ui_test_utils.h b/chrome/test/ui_test_utils.h
index 5299451be35246be39bc9230e5cf3b76bc54d62c..323e3744a44fe16e5afc83816eb9effab2d68b0c 100644
--- a/chrome/test/ui_test_utils.h
+++ b/chrome/test/ui_test_utils.h
@@ -280,12 +280,15 @@ class TimedMessageLoopRunner {
// server.
class TestWebSocketServer {
public:
- // Creates and starts a python websocket server with |root_directory|.
- explicit TestWebSocketServer(const FilePath& root_directory);
+ TestWebSocketServer();
- // Destroys and stops the server.
+ // Stops the python websocket server if it was already started.
~TestWebSocketServer();
+ // Starts the python websocket server using |root_directory|. Returns whether
+ // the server was successfully started.
+ bool Start(const FilePath& root_directory);
+
private:
// Sets up PYTHONPATH to run websocket_server.py.
void SetPythonPath();
@@ -296,6 +299,9 @@ class TestWebSocketServer {
// Creates a CommandLine for invoking the python websocker server.
CommandLine* CreateWebSocketServerCommandLine();
+ // Has the server been started?
+ bool started_;
+
// A Scoped temporary directory for holding the python pid file.
ScopedTempDir temp_dir_;

Powered by Google App Engine
This is Rietveld 408576698