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

Unified Diff: mojo/edk/test/mojo_test_base.h

Issue 1748503002: [mojo-edk] Add MojoWatch and MojoCancelWatch APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert RequestContext usage, nits Created 4 years, 10 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 | « mojo/edk/system/watcher_set.cc ('k') | mojo/edk/test/mojo_test_base.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/edk/test/mojo_test_base.h
diff --git a/mojo/edk/test/mojo_test_base.h b/mojo/edk/test/mojo_test_base.h
index e44316dfde0a4c51e474997e1899d435583a6753..71c92763930e653636a4fe52a284a9b86184b8f2 100644
--- a/mojo/edk/test/mojo_test_base.h
+++ b/mojo/edk/test/mojo_test_base.h
@@ -14,10 +14,6 @@
#include "base/macros.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
-#include "base/message_loop/message_loop.h"
-#include "base/run_loop.h"
-#include "base/task_runner.h"
-#include "base/thread_task_runner_handle.h"
#include "mojo/edk/embedder/embedder.h"
#include "mojo/edk/test/multiprocess_test_helper.h"
#include "mojo/public/c/system/types.h"
@@ -131,10 +127,22 @@ class MojoTestBase : public testing::Test {
size_t offset,
const base::StringPiece& s);
+ //////// Data pipe test utilities /////////
+
+ // Creates a new data pipe.
+ static void CreateDataPipe(MojoHandle* producer,
+ MojoHandle* consumer,
+ size_t capacity);
+
+ // Writes data to a data pipe.
+ static void WriteData(MojoHandle producer, const std::string& data);
+
+ // Reads data from a data pipe.
+ static std::string ReadData(MojoHandle consumer, size_t size);
+
private:
friend class ClientController;
- base::MessageLoop message_loop_;
std::vector<scoped_ptr<ClientController>> clients_;
DISALLOW_COPY_AND_ASSIGN(MojoTestBase);
« no previous file with comments | « mojo/edk/system/watcher_set.cc ('k') | mojo/edk/test/mojo_test_base.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698