summaryrefslogtreecommitdiffstats
path: root/chrome/browser/password_manager
diff options
context:
space:
mode:
authortommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-02 11:42:59 +0000
committertommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-02 11:42:59 +0000
commit86af1af90faf06b91de9eea2642cf10627839d3b (patch)
tree3267423792abc68624c057a725cd5f47c602b774 /chrome/browser/password_manager
parent631bb742a2798549af691af7357236ce0899b4cb (diff)
downloadchromium_src-86af1af90faf06b91de9eea2642cf10627839d3b.zip
chromium_src-86af1af90faf06b91de9eea2642cf10627839d3b.tar.gz
chromium_src-86af1af90faf06b91de9eea2642cf10627839d3b.tar.bz2
Moving the SignalingTask class to base/test.
As requested in another review (http://codereview.chromium.org/8427031/diff/1009/content/renderer/media/webrtc_audio_device_unittest.cc#newcode132). so that it can be reused in content tests. TEST=none BUG=none Review URL: http://codereview.chromium.org/8438034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@108271 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/password_manager')
-rw-r--r--chrome/browser/password_manager/password_store_default_unittest.cc20
-rw-r--r--chrome/browser/password_manager/password_store_win_unittest.cc14
-rw-r--r--chrome/browser/password_manager/password_store_x_unittest.cc24
3 files changed, 29 insertions, 29 deletions
diff --git a/chrome/browser/password_manager/password_store_default_unittest.cc b/chrome/browser/password_manager/password_store_default_unittest.cc
index ee3f832..006cb70 100644
--- a/chrome/browser/password_manager/password_store_default_unittest.cc
+++ b/chrome/browser/password_manager/password_store_default_unittest.cc
@@ -7,6 +7,7 @@
#include "base/stl_util.h"
#include "base/string_util.h"
#include "base/synchronization/waitable_event.h"
+#include "base/test/signaling_task.h"
#include "base/time.h"
#include "base/utf_string_conversions.h"
#include "chrome/browser/password_manager/password_form_data.h"
@@ -17,7 +18,6 @@
#include "chrome/browser/webdata/web_data_service.h"
#include "chrome/common/chrome_notification_types.h"
#include "chrome/common/pref_names.h"
-#include "chrome/test/base/signaling_task.h"
#include "chrome/test/base/testing_profile.h"
#include "content/public/browser/notification_details.h"
#include "content/public/browser/notification_registrar.h"
@@ -191,7 +191,7 @@ TEST_F(PasswordStoreDefaultTest, NonASCIIData) {
// yet another task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
MockPasswordStoreConsumer consumer;
@@ -286,7 +286,7 @@ TEST_F(PasswordStoreDefaultTest, Migration) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Initializing the PasswordStore should trigger a migration.
@@ -302,7 +302,7 @@ TEST_F(PasswordStoreDefaultTest, Migration) {
// Again, the WDS schedules tasks to run on the DB thread, so schedule a task
// to signal us when it is safe to continue.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Let the WDS callbacks proceed so the logins can be migrated.
@@ -347,7 +347,7 @@ TEST_F(PasswordStoreDefaultTest, Migration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
@@ -361,7 +361,7 @@ TEST_F(PasswordStoreDefaultTest, Migration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
@@ -399,7 +399,7 @@ TEST_F(PasswordStoreDefaultTest, MigrationAlreadyDone) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Pretend that the migration has already taken place.
@@ -479,7 +479,7 @@ TEST_F(PasswordStoreDefaultTest, Notifications) {
// yet another task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Change the password.
@@ -501,7 +501,7 @@ TEST_F(PasswordStoreDefaultTest, Notifications) {
// Wait for PasswordStore to send the notification.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
const PasswordStoreChange expected_delete_changes[] = {
@@ -520,7 +520,7 @@ TEST_F(PasswordStoreDefaultTest, Notifications) {
// Wait for PasswordStore to send the notification.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
store->Shutdown();
diff --git a/chrome/browser/password_manager/password_store_win_unittest.cc b/chrome/browser/password_manager/password_store_win_unittest.cc
index 3881bff..b5192c3 100644
--- a/chrome/browser/password_manager/password_store_win_unittest.cc
+++ b/chrome/browser/password_manager/password_store_win_unittest.cc
@@ -12,6 +12,7 @@
#include "base/scoped_temp_dir.h"
#include "base/stl_util.h"
#include "base/synchronization/waitable_event.h"
+#include "base/test/signaling_task.h"
#include "base/time.h"
#include "chrome/browser/password_manager/ie7_password.h"
#include "chrome/browser/password_manager/password_form_data.h"
@@ -20,7 +21,6 @@
#include "chrome/browser/prefs/pref_service.h"
#include "chrome/browser/webdata/web_data_service.h"
#include "chrome/common/pref_names.h"
-#include "chrome/test/base/signaling_task.h"
#include "chrome/test/base/testing_profile.h"
#include "content/test/test_browser_thread.h"
#include "testing/gmock/include/gmock/gmock.h"
@@ -166,7 +166,7 @@ TEST_F(PasswordStoreWinTest, DISABLED_ConvertIE7Login) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Prentend that the migration has already taken place.
@@ -278,7 +278,7 @@ TEST_F(PasswordStoreWinTest, DISABLED_MultipleWDSQueriesOnDifferentThreads) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Prentend that the migration has already taken place.
@@ -434,7 +434,7 @@ TEST_F(PasswordStoreWinTest, Migration) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Initializing the PasswordStore should trigger a migration.
@@ -449,7 +449,7 @@ TEST_F(PasswordStoreWinTest, Migration) {
// Again, the WDS schedules tasks to run on the DB thread, so schedule a task
// to signal us when it is safe to continue.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Let the WDS callbacks proceed so the logins can be migrated.
@@ -494,7 +494,7 @@ TEST_F(PasswordStoreWinTest, Migration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
@@ -508,7 +508,7 @@ TEST_F(PasswordStoreWinTest, Migration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
diff --git a/chrome/browser/password_manager/password_store_x_unittest.cc b/chrome/browser/password_manager/password_store_x_unittest.cc
index a2df5ea..7bce400 100644
--- a/chrome/browser/password_manager/password_store_x_unittest.cc
+++ b/chrome/browser/password_manager/password_store_x_unittest.cc
@@ -11,6 +11,7 @@
#include "base/string_util.h"
#include "base/stringprintf.h"
#include "base/synchronization/waitable_event.h"
+#include "base/test/signaling_task.h"
#include "base/time.h"
#include "base/utf_string_conversions.h"
#include "chrome/browser/password_manager/password_form_data.h"
@@ -21,7 +22,6 @@
#include "chrome/browser/webdata/web_data_service.h"
#include "chrome/common/chrome_notification_types.h"
#include "chrome/common/pref_names.h"
-#include "chrome/test/base/signaling_task.h"
#include "chrome/test/base/testing_browser_process.h"
#include "chrome/test/base/testing_profile.h"
#include "content/public/browser/notification_details.h"
@@ -360,7 +360,7 @@ TEST_P(PasswordStoreXTest, WDSMigration) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Initializing the PasswordStore should trigger a migration.
@@ -378,7 +378,7 @@ TEST_P(PasswordStoreXTest, WDSMigration) {
// Again, the WDS schedules tasks to run on the DB thread, so schedule a task
// to signal us when it is safe to continue.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Let the WDS callbacks proceed so the logins can be migrated.
@@ -423,7 +423,7 @@ TEST_P(PasswordStoreXTest, WDSMigration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
@@ -437,7 +437,7 @@ TEST_P(PasswordStoreXTest, WDSMigration) {
// Wait for the WDS methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Handle the callback from the WDS.
@@ -480,7 +480,7 @@ TEST_P(PasswordStoreXTest, WDSMigrationAlreadyDone) {
// task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Pretend that the migration has already taken place.
@@ -565,7 +565,7 @@ TEST_P(PasswordStoreXTest, Notifications) {
// yet another task to notify us that it's safe to carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Change the password.
@@ -587,7 +587,7 @@ TEST_P(PasswordStoreXTest, Notifications) {
// Wait for PasswordStore to send the notification.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
const PasswordStoreChange expected_delete_changes[] = {
@@ -606,7 +606,7 @@ TEST_P(PasswordStoreXTest, Notifications) {
// Wait for PasswordStore to send the notification.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Public in PasswordStore, protected in PasswordStoreX.
@@ -648,7 +648,7 @@ TEST_P(PasswordStoreXTest, NativeMigration) {
// carry on with the test.
WaitableEvent done(false, false);
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
// Get the new size of the login DB file. We expect it to be larger.
@@ -713,7 +713,7 @@ TEST_P(PasswordStoreXTest, NativeMigration) {
// Wait for the login DB methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
if (GetParam() == WORKING_BACKEND) {
@@ -733,7 +733,7 @@ TEST_P(PasswordStoreXTest, NativeMigration) {
// Wait for the login DB methods to execute on the DB thread.
BrowserThread::PostTask(BrowserThread::DB, FROM_HERE,
- new SignalingTask(&done));
+ new base::SignalingTask(&done));
done.Wait();
if (GetParam() == WORKING_BACKEND) {