| Index: chrome/browser/sync/glue/autofill_data_type_controller_unittest.cc
|
| diff --git a/chrome/browser/sync/glue/autofill_data_type_controller_unittest.cc b/chrome/browser/sync/glue/autofill_data_type_controller_unittest.cc
|
| index 316829a03fec2e9113e4f50ca485cf238edad845..46109a0b9770d23395f75b44c96b4bae08436cdc 100644
|
| --- a/chrome/browser/sync/glue/autofill_data_type_controller_unittest.cc
|
| +++ b/chrome/browser/sync/glue/autofill_data_type_controller_unittest.cc
|
| @@ -31,6 +31,7 @@
|
| #include "testing/gtest/include/gtest/gtest.h"
|
|
|
| using autofill::AutofillWebDataService;
|
| +using autofill::AutofillWebDataBackend;
|
|
|
| namespace browser_sync {
|
|
|
| @@ -41,6 +42,19 @@ using testing::_;
|
| using testing::NiceMock;
|
| using testing::Return;
|
|
|
| +class NoOpAutofillBackend : public AutofillWebDataBackend {
|
| + public:
|
| + NoOpAutofillBackend() {}
|
| + virtual ~NoOpAutofillBackend() {}
|
| + virtual WebDatabase* GetDatabase() OVERRIDE { return NULL; }
|
| + virtual void AddObserver(
|
| + autofill::AutofillWebDataServiceObserverOnDBThread* observer) OVERRIDE {}
|
| + virtual void RemoveObserver(
|
| + autofill::AutofillWebDataServiceObserverOnDBThread* observer) OVERRIDE {}
|
| + virtual void RemoveExpiredFormElements() OVERRIDE {}
|
| + virtual void NotifyOfMultipleAutofillChanges() OVERRIDE {}
|
| +};
|
| +
|
| // Fake WebDataService implementation that stubs out the database loading.
|
| class FakeWebDataService : public AutofillWebDataService {
|
| public:
|
| @@ -120,11 +134,13 @@ class FakeWebDataService : public AutofillWebDataService {
|
| void CreateSyncableService() {
|
| ASSERT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::DB));
|
| // These services are deleted in DestroySyncableService().
|
| - AutocompleteSyncableService::CreateForWebDataService(this);
|
| + AutocompleteSyncableService::CreateForWebDataServiceAndBackend(
|
| + this,
|
| + &autofill_backend_);
|
| }
|
|
|
| bool is_database_loaded_;
|
| -
|
| + NoOpAutofillBackend autofill_backend_;
|
| WebDatabaseObserver* observer_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(FakeWebDataService);
|
|
|