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

Unified Diff: net/socket/socket_test_util.h

Issue 1124533002: Add CompleteRead to SequencedSocketData and convert all but 3 tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 7 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 | « net/socket/sequenced_socket_data_unittest.cc ('k') | net/socket/socket_test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/socket_test_util.h
diff --git a/net/socket/socket_test_util.h b/net/socket/socket_test_util.h
index 1048c964751cf8ec02cf49f9a641b0b4b4ff5f2c..410512df8095081d054e2b50708faa50eef05a98 100644
--- a/net/socket/socket_test_util.h
+++ b/net/socket/socket_test_util.h
@@ -512,6 +512,9 @@ class SequencedSocketData : public SocketDataProvider {
// Returns true if all data has been written.
bool at_write_eof() const;
+ bool IsReadPaused();
+ void CompleteRead();
+
private:
// Defines the state for the read or write path.
enum IoState {
@@ -519,7 +522,9 @@ class SequencedSocketData : public SocketDataProvider {
PENDING, // An async operation in waiting for another opteration to
// complete.
COMPLETING, // A task has been posted to complet an async operation.
+ PAUSED, // IO is paused until CompleteRead() is called.
};
+
void OnReadComplete();
void OnWriteComplete();
« no previous file with comments | « net/socket/sequenced_socket_data_unittest.cc ('k') | net/socket/socket_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698