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

Side by Side Diff: components/sync/driver/glue/sync_backend_host_impl_unittest.cc

Issue 2859033002: [sync] Add constexpr to EnumSet (Closed)
Patch Set: Move reading list switches and buildflag to /features Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/sync/driver/glue/sync_backend_host_impl.h" 5 #include "components/sync/driver/glue/sync_backend_host_impl.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/files/file_util.h" 10 #include "base/files/file_util.h"
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after
341 EXPECT_EQ(enabled_types_, fake_manager_->InitialSyncEndedTypes()); 341 EXPECT_EQ(enabled_types_, fake_manager_->InitialSyncEndedTypes());
342 EXPECT_TRUE( 342 EXPECT_TRUE(
343 fake_manager_->GetTypesWithEmptyProgressMarkerToken(enabled_types_) 343 fake_manager_->GetTypesWithEmptyProgressMarkerToken(enabled_types_)
344 .Empty()); 344 .Empty());
345 } 345 }
346 346
347 // Test the restart after setting up sync scenario. No enabled types should be 347 // Test the restart after setting up sync scenario. No enabled types should be
348 // downloaded or cleaned. 348 // downloaded or cleaned.
349 TEST_F(SyncEngineTest, Restart) { 349 TEST_F(SyncEngineTest, Restart) {
350 sync_prefs_->SetFirstSetupComplete(); 350 sync_prefs_->SetFirstSetupComplete();
351 ModelTypeSet all_but_nigori = enabled_types_;
352 fake_manager_factory_->set_progress_marker_types(enabled_types_); 351 fake_manager_factory_->set_progress_marker_types(enabled_types_);
353 fake_manager_factory_->set_initial_sync_ended_types(enabled_types_); 352 fake_manager_factory_->set_initial_sync_ended_types(enabled_types_);
354 InitializeBackend(true); 353 InitializeBackend(true);
355 EXPECT_TRUE(fake_manager_->GetAndResetDownloadedTypes().Empty()); 354 EXPECT_TRUE(fake_manager_->GetAndResetDownloadedTypes().Empty());
356 EXPECT_TRUE( 355 EXPECT_TRUE(
357 Intersection(fake_manager_->GetAndResetPurgedTypes(), enabled_types_) 356 Intersection(fake_manager_->GetAndResetPurgedTypes(), enabled_types_)
358 .Empty()); 357 .Empty());
359 EXPECT_EQ(enabled_types_, fake_manager_->InitialSyncEndedTypes()); 358 EXPECT_EQ(enabled_types_, fake_manager_->InitialSyncEndedTypes());
360 EXPECT_TRUE( 359 EXPECT_TRUE(
361 fake_manager_->GetTypesWithEmptyProgressMarkerToken(enabled_types_) 360 fake_manager_->GetTypesWithEmptyProgressMarkerToken(enabled_types_)
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
816 backend_->StopSyncingForShutdown(); 815 backend_->StopSyncingForShutdown();
817 // Verify that call to DeactivateNonBlockingDataType doesn't assert. 816 // Verify that call to DeactivateNonBlockingDataType doesn't assert.
818 backend_->DeactivateNonBlockingDataType(AUTOFILL); 817 backend_->DeactivateNonBlockingDataType(AUTOFILL);
819 backend_->Shutdown(STOP_SYNC); 818 backend_->Shutdown(STOP_SYNC);
820 backend_.reset(); 819 backend_.reset();
821 } 820 }
822 821
823 } // namespace 822 } // namespace
824 823
825 } // namespace syncer 824 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/driver/data_type_manager_impl.cc ('k') | components/sync/engine_impl/sync_encryption_handler_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698