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

Unified Diff: components/sync/engine_impl/js_mutation_event_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_mutation_event_observer_unittest.cc
diff --git a/components/sync/engine_impl/js_mutation_event_observer_unittest.cc b/components/sync/engine_impl/js_mutation_event_observer_unittest.cc
index a6dfe74ac3519bccc31e11c8a9e2a03dcf2c4feb..1a8da574aef4618f112f6e3aaa5ee36d6e13644a 100644
--- a/components/sync/engine_impl/js_mutation_event_observer_unittest.cc
+++ b/components/sync/engine_impl/js_mutation_event_observer_unittest.cc
@@ -5,6 +5,7 @@
#include "components/sync/engine_impl/js_mutation_event_observer.h"
#include "base/run_loop.h"
+#include "base/test/scoped_task_environment.h"
#include "base/values.h"
#include "components/sync/base/model_type.h"
#include "components/sync/js/js_event_details.h"
@@ -27,7 +28,7 @@ class JsMutationEventObserverTest : 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