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

Side by Side Diff: components/sync/device_info/device_info_util_unittest.cc

Issue 2376123003: [Sync] Move //components/sync to the syncer namespace. (Closed)
Patch Set: Rebase. Created 4 years, 2 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 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/device_info/device_info_util.h" 5 #include "components/sync/device_info/device_info_util.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "components/sync/protocol/sync.pb.h" 9 #include "components/sync/protocol/sync.pb.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
11 11
12 using base::Time; 12 using base::Time;
13 using base::TimeDelta; 13 using base::TimeDelta;
14 using sync_pb::DeviceInfoSpecifics; 14 using sync_pb::DeviceInfoSpecifics;
15 15
16 namespace sync_driver { 16 namespace syncer {
17 17
18 namespace { 18 namespace {
19 19
20 class DeviceInfoUtilTest : public testing::Test { 20 class DeviceInfoUtilTest : public testing::Test {
21 protected: 21 protected:
22 DeviceInfoUtilTest() { 22 DeviceInfoUtilTest() {
23 // Test cases assume |small_| and |big_| are smaller and bigger, 23 // Test cases assume |small_| and |big_| are smaller and bigger,
24 // respectively, 24 // respectively,
25 // than both constants. 25 // than both constants.
26 EXPECT_LT(small_, DeviceInfoUtil::kActiveThreshold); 26 EXPECT_LT(small_, DeviceInfoUtil::kActiveThreshold);
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 specifics.set_cache_guid(cache_guid); 103 specifics.set_cache_guid(cache_guid);
104 ASSERT_EQ(cache_guid, DeviceInfoUtil::TagToCacheGuid( 104 ASSERT_EQ(cache_guid, DeviceInfoUtil::TagToCacheGuid(
105 DeviceInfoUtil::SpecificsToTag(specifics))); 105 DeviceInfoUtil::SpecificsToTag(specifics)));
106 106
107 specifics.set_cache_guid(DeviceInfoUtil::kClientTagPrefix); 107 specifics.set_cache_guid(DeviceInfoUtil::kClientTagPrefix);
108 ASSERT_EQ(DeviceInfoUtil::kClientTagPrefix, 108 ASSERT_EQ(DeviceInfoUtil::kClientTagPrefix,
109 DeviceInfoUtil::TagToCacheGuid( 109 DeviceInfoUtil::TagToCacheGuid(
110 DeviceInfoUtil::SpecificsToTag(specifics))); 110 DeviceInfoUtil::SpecificsToTag(specifics)));
111 } 111 }
112 112
113 } // namespace sync_driver 113 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/device_info/device_info_util.cc ('k') | components/sync/device_info/local_device_info_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698