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

Unified Diff: content/public/test/test_browser_thread_bundle.h

Issue 2860533002: Support base::test::ScopedTaskEnvironment and content::TestBrowserThreadBundle in the same scope. (Closed)
Patch Set: remove check failed Created 3 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 | « no previous file | content/public/test/test_browser_thread_bundle.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/test_browser_thread_bundle.h
diff --git a/content/public/test/test_browser_thread_bundle.h b/content/public/test/test_browser_thread_bundle.h
index c8f85deb2a5378de47e4d1b1badfc14f6f2b160e..ec57c5b36dfcc80feed73d6252da2cd8630633e1 100644
--- a/content/public/test/test_browser_thread_bundle.h
+++ b/content/public/test/test_browser_thread_bundle.h
@@ -54,6 +54,15 @@
// DONT_CREATE_THREADS should only be used when the options specify at least
// one real thread other than the main thread.
//
+// TestBrowserThreadBundle may be instantiated in a scope where there is already
+// a base::test::ScopedTaskEnvironment. In that case, it will use the
+// MessageLoop and the TaskScheduler provided by this
+// base::test::ScopedTaskEnvironment instead of creating its own. The ability to
+// have a base::test::ScopedTaskEnvironment and a TestBrowserThreadBundle in the
+// same scope is useful when a fixture that inherits from a fixture that
+// provides a base::test::ScopedTaskEnvironment needs to add support for browser
+// threads.
+//
// Basic usage:
//
// class MyTestFixture : public testing::Test {
« no previous file with comments | « no previous file | content/public/test/test_browser_thread_bundle.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698