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

Unified Diff: chrome/browser/sync/glue/theme_data_type_controller_unittest.cc

Issue 9978017: [Sync] - Upload the callstacks for errors so that the line number of error is in callstack. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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/sync/glue/theme_data_type_controller_unittest.cc
diff --git a/chrome/browser/sync/glue/theme_data_type_controller_unittest.cc b/chrome/browser/sync/glue/theme_data_type_controller_unittest.cc
index a684dc7383cffe044418fec62077ee98ae8f224e..48cbc77c1c2c73e59fd02da9086a20ac6eaa4a78 100644
--- a/chrome/browser/sync/glue/theme_data_type_controller_unittest.cc
+++ b/chrome/browser/sync/glue/theme_data_type_controller_unittest.cc
@@ -56,8 +56,8 @@ class SyncThemeDataTypeControllerTest : public testing::Test {
WillRepeatedly(Return(true));
EXPECT_CALL(*model_associator_, SyncModelHasUserCreatedNodes(_)).
WillRepeatedly(DoAll(SetArgumentPointee<0>(true), Return(true)));
- EXPECT_CALL(*model_associator_, AssociateModels(_)).
- WillRepeatedly(Return(true));
+ EXPECT_CALL(*model_associator_, AssociateModels()).
+ WillRepeatedly(Return(SyncError()));
}
void SetActivateExpectations() {
@@ -66,7 +66,8 @@ class SyncThemeDataTypeControllerTest : public testing::Test {
void SetStopExpectations() {
EXPECT_CALL(service_, DeactivateDataType(_));
- EXPECT_CALL(*model_associator_, DisassociateModels(_));
+ EXPECT_CALL(*model_associator_, DisassociateModels()).
+ WillOnce(Return(SyncError()));
}
void PumpLoop() {
@@ -121,9 +122,8 @@ TEST_F(SyncThemeDataTypeControllerTest, StartOk) {
TEST_F(SyncThemeDataTypeControllerTest, StartAssociationFailed) {
SetStartExpectations();
SetAssociateExpectations();
- EXPECT_CALL(*model_associator_, AssociateModels(_)).
- WillRepeatedly(DoAll(browser_sync::SetSyncError(syncable::THEMES),
- Return(false)));
+ EXPECT_CALL(*model_associator_, AssociateModels()).
+ WillRepeatedly(Return(SyncError(FROM_HERE, "Error", syncable::THEMES)));
EXPECT_CALL(start_callback_,
Run(DataTypeController::ASSOCIATION_FAILED, _));
« no previous file with comments | « chrome/browser/sync/glue/session_model_associator.cc ('k') | chrome/browser/sync/glue/theme_model_associator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698