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

Unified Diff: components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc

Issue 2798963003: Use ScopedTaskEnvironment instead of MessageLoop in components unit tests. (Closed)
Patch Set: Created 3 years, 8 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: components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc
diff --git a/components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc b/components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc
index ff3f04e7e97b2a5c0e58e21d7ecaa02cfcb7001c..8ce7f06b28e56fc7a7f997ccf1a50d35829cec05 100644
--- a/components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc
+++ b/components/sync/engine_impl/js_sync_encryption_handler_observer_unittest.cc
@@ -6,6 +6,7 @@
#include "base/location.h"
#include "base/run_loop.h"
+#include "base/test/scoped_task_environment.h"
#include "base/values.h"
#include "components/sync/base/cryptographer.h"
#include "components/sync/base/fake_encryptor.h"
@@ -33,7 +34,7 @@ class JsSyncEncryptionHandlerObserverTest : public testing::Test {
private:
// This must be destroyed after the member variables below in order
// for WeakHandles to be destroyed properly.
- base::MessageLoop message_loop_;
+ base::test::ScopedTaskEnvironment scoped_task_environment_;
protected:
StrictMock<MockJsEventHandler> mock_js_event_handler_;

Powered by Google App Engine
This is Rietveld 408576698