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

Unified Diff: chrome/browser/password_manager/password_manager_internals_service_unittest.cc

Issue 1086733002: Ensure tests have an active task runner (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 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: chrome/browser/password_manager/password_manager_internals_service_unittest.cc
diff --git a/chrome/browser/password_manager/password_manager_internals_service_unittest.cc b/chrome/browser/password_manager/password_manager_internals_service_unittest.cc
index 82b7ffe9c49d7dd4c324316abf3a345534855c8b..07baddeb9695145175fd74fba10e7bfc38951c32 100644
--- a/chrome/browser/password_manager/password_manager_internals_service_unittest.cc
+++ b/chrome/browser/password_manager/password_manager_internals_service_unittest.cc
@@ -8,6 +8,7 @@
#include "components/keyed_service/content/browser_context_dependency_manager.h"
#include "components/password_manager/content/browser/password_manager_internals_service_factory.h"
#include "components/password_manager/core/browser/log_receiver.h"
+#include "content/public/test/test_browser_thread_bundle.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -46,9 +47,13 @@ scoped_ptr<TestingProfile> CreateProfile(ProfileType type) {
} // namespace
+class PasswordManagerInternalsServiceTest : public testing::Test {
+ content::TestBrowserThreadBundle thread_bundle_;
+};
+
// When the profile is not incognito, it should be possible to activate the
// service.
-TEST(PasswordManagerInternalsServiceTest, ServiceActiveNonIncognito) {
+TEST_F(PasswordManagerInternalsServiceTest, ServiceActiveNonIncognito) {
scoped_ptr<TestingProfile> profile(CreateProfile(NORMAL_PROFILE));
PasswordManagerInternalsService* service =
PasswordManagerInternalsServiceFactory::GetForBrowserContext(
@@ -68,7 +73,7 @@ TEST(PasswordManagerInternalsServiceTest, ServiceActiveNonIncognito) {
// When the browser profile is incognito, it should not be possible to activate
// the service.
-TEST(PasswordManagerInternalsServiceTest, ServiceNotActiveIncognito) {
+TEST_F(PasswordManagerInternalsServiceTest, ServiceNotActiveIncognito) {
scoped_ptr<TestingProfile> profile(CreateProfile(INCOGNITO_PROFILE));
ASSERT_TRUE(profile);

Powered by Google App Engine
This is Rietveld 408576698