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

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

Issue 594643003: Device info datatype should be moved to components/sync_driver. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed CR feedback Created 6 years, 3 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/local_device_info_provider_unittest.cc
diff --git a/chrome/browser/sync/glue/local_device_info_provider_unittest.cc b/chrome/browser/sync/glue/local_device_info_provider_unittest.cc
index d1fb4ebf5374bb378b06a1ed62b9eb82b2768122..f09f59bc3a533862caf1d032b1b5971756275cc8 100644
--- a/chrome/browser/sync/glue/local_device_info_provider_unittest.cc
+++ b/chrome/browser/sync/glue/local_device_info_provider_unittest.cc
@@ -2,9 +2,12 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "base/bind.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "chrome/browser/sync/glue/local_device_info_provider_impl.h"
+#include "chrome/common/chrome_version_info.h"
+#include "sync/util/get_session_name.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace browser_sync {
@@ -72,6 +75,13 @@ TEST_F(LocalDeviceInfoProviderTest, GetLocalDeviceInfo) {
EXPECT_EQ(std::string(kLocalDeviceGuid), local_device_info->guid());
EXPECT_EQ(std::string(kSigninScopedDeviceId),
local_device_info->signin_scoped_device_id());
+ EXPECT_EQ(syncer::GetSessionNameSynchronouslyForTesting(),
+ local_device_info->client_name());
+
+ chrome::VersionInfo version_info;
+ EXPECT_EQ(browser_sync::LocalDeviceInfoProviderImpl::MakeUserAgentForSyncApi(
+ version_info),
+ local_device_info->sync_user_agent());
}
TEST_F(LocalDeviceInfoProviderTest, GetLocalSyncCacheGUID) {
« no previous file with comments | « chrome/browser/sync/glue/local_device_info_provider_impl.cc ('k') | chrome/browser/sync/glue/sync_backend_host_core.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698