Chromium Code Reviews| Index: net/base/test_completion_callback.h |
| diff --git a/net/base/test_completion_callback.h b/net/base/test_completion_callback.h |
| index f5a9f8da7453d81ddc0cd1f2f31f3bac3b9d86f1..cbbfbe730081c02de3c70e2a14e64caf9e92ba2c 100644 |
| --- a/net/base/test_completion_callback.h |
| +++ b/net/base/test_completion_callback.h |
| @@ -5,6 +5,7 @@ |
| #ifndef NET_BASE_TEST_COMPLETION_CALLBACK_H_ |
| #define NET_BASE_TEST_COMPLETION_CALLBACK_H_ |
| +#include "base/callback.h" |
| #include "base/compiler_specific.h" |
| #include "base/tuple.h" |
| #include "net/base/completion_callback.h" |
| @@ -77,6 +78,22 @@ class TestCompletionCallbackTemplate |
| } // namespace internal |
| +class TestClosureCallback |
| + : public internal::TestCompletionCallbackBaseInternal { |
| + public: |
| + TestClosureCallback(); |
| + ~TestClosureCallback(); |
|
jkarlin
2014/11/03 19:17:59
virtual override
gavinp
2014/11/03 22:54:48
Sure. I have to update a bunch of base classes; bu
|
| + |
| + using internal::TestCompletionCallbackBaseInternal::WaitForResult; |
|
jkarlin
2014/11/03 19:17:59
Why is this necessary?
gavinp
2014/11/03 22:54:48
Because TestCompletionCallbackBaseInternal::WaitFo
|
| + |
| + const base::Closure& callback() const { return callback_; } |
| + |
| + private: |
| + const base::Closure callback_; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(TestClosureCallback); |
| +}; |
| + |
| // Base class overridden by custom implementations of TestCompletionCallback. |
| typedef internal::TestCompletionCallbackTemplate<int> |
| TestCompletionCallbackBase; |