| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/model_impl/accumulating_metadata_change_list.h" | 5 #include "components/sync/model_impl/accumulating_metadata_change_list.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/message_loop/message_loop.h" |
| 10 #include "base/run_loop.h" | 11 #include "base/run_loop.h" |
| 11 #include "components/sync/model/mock_model_type_store.h" | 12 #include "components/sync/model/mock_model_type_store.h" |
| 12 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
| 13 | 14 |
| 14 namespace syncer { | 15 namespace syncer { |
| 15 namespace { | 16 namespace { |
| 16 | 17 |
| 17 using WriteBatch = ModelTypeStore::WriteBatch; | 18 using WriteBatch = ModelTypeStore::WriteBatch; |
| 18 | 19 |
| 19 void RecordMetadataWrite(std::map<std::string, std::string>* map, | 20 void RecordMetadataWrite(std::map<std::string, std::string>* map, |
| (...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 cl.TransferChanges(store(), batch.get()); | 198 cl.TransferChanges(store(), batch.get()); |
| 198 | 199 |
| 199 EXPECT_TRUE(delete_set.find("client_tag") != delete_set.end()); | 200 EXPECT_TRUE(delete_set.find("client_tag") != delete_set.end()); |
| 200 EXPECT_TRUE(change_map.find("client_tag") == change_map.end()); | 201 EXPECT_TRUE(change_map.find("client_tag") == change_map.end()); |
| 201 EXPECT_TRUE(delete_called); | 202 EXPECT_TRUE(delete_called); |
| 202 EXPECT_TRUE(global_metadata.empty()); | 203 EXPECT_TRUE(global_metadata.empty()); |
| 203 } | 204 } |
| 204 | 205 |
| 205 } // namespace | 206 } // namespace |
| 206 } // namespace syncer | 207 } // namespace syncer |
| OLD | NEW |