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

Unified Diff: chrome/browser/sync/protocol/proto_enum_conversions_unittest.cc

Issue 9699057: [Sync] Move 'sync' target to sync/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address Tim's comments Created 8 years, 9 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/protocol/proto_enum_conversions_unittest.cc
diff --git a/chrome/browser/sync/protocol/proto_enum_conversions_unittest.cc b/chrome/browser/sync/protocol/proto_enum_conversions_unittest.cc
deleted file mode 100644
index 648cfe6232556f6e256be575e8d6167b698ae143..0000000000000000000000000000000000000000
--- a/chrome/browser/sync/protocol/proto_enum_conversions_unittest.cc
+++ /dev/null
@@ -1,62 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Keep this file in sync with the .proto files in this directory.
-
-#include "chrome/browser/sync/protocol/proto_enum_conversions.h"
-
-#include <string>
-
-#include "testing/gtest/include/gtest/gtest.h"
-
-namespace browser_sync {
-namespace {
-
-class ProtoEnumConversionsTest : public testing::Test {
-};
-
-template <class T>
-void TestEnumStringFunction(const char* (*enum_string_fn)(T),
- int enum_min, int enum_max) {
- for (int i = enum_min; i <= enum_max; ++i) {
- const std::string& str = enum_string_fn(static_cast<T>(i));
- EXPECT_FALSE(str.empty());
- }
-}
-
-TEST_F(ProtoEnumConversionsTest, GetBrowserTypeString) {
- TestEnumStringFunction(
- GetBrowserTypeString,
- sync_pb::SessionWindow::BrowserType_MIN,
- sync_pb::SessionWindow::BrowserType_MAX);
-}
-
-TEST_F(ProtoEnumConversionsTest, GetPageTransitionString) {
- // We have a gap, so we need to do two ranges.
- TestEnumStringFunction(
- GetPageTransitionString,
- sync_pb::TabNavigation::PageTransition_MIN,
- sync_pb::TabNavigation::KEYWORD_GENERATED);
- TestEnumStringFunction(
- GetPageTransitionString,
- sync_pb::TabNavigation::CHAIN_START,
- sync_pb::TabNavigation::PageTransition_MAX);
-}
-
-TEST_F(ProtoEnumConversionsTest, GetPageTransitionQualifierString) {
- TestEnumStringFunction(
- GetPageTransitionQualifierString,
- sync_pb::TabNavigation::PageTransitionQualifier_MIN,
- sync_pb::TabNavigation::PageTransitionQualifier_MAX);
-}
-
-TEST_F(ProtoEnumConversionsTest, GetUpdatesSourceString) {
- TestEnumStringFunction(
- GetUpdatesSourceString,
- sync_pb::GetUpdatesCallerInfo::GetUpdatesSource_MIN,
- sync_pb::GetUpdatesCallerInfo::GetUpdatesSource_MAX);
-}
-
-} // namespace
-} // namespace browser_sync
« no previous file with comments | « chrome/browser/sync/protocol/proto_enum_conversions.cc ('k') | chrome/browser/sync/protocol/proto_value_conversions.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698