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

Side by Side Diff: components/user_prefs/tracked/pref_hash_calculator_unittest.cc

Issue 1549993003: Switch to standard integer types in components/, part 4 of 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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/user_prefs/tracked/pref_hash_calculator.h" 5 #include "components/user_prefs/tracked/pref_hash_calculator.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
10 #include "base/strings/string_util.h" 11 #include "base/strings/string_util.h"
11 #include "base/values.h" 12 #include "base/values.h"
12 #include "testing/gtest/include/gtest/gtest.h" 13 #include "testing/gtest/include/gtest/gtest.h"
13 14
14 TEST(PrefHashCalculatorTest, TestCurrentAlgorithm) { 15 TEST(PrefHashCalculatorTest, TestCurrentAlgorithm) {
15 base::StringValue string_value_1("string value 1"); 16 base::StringValue string_value_1("string value 1");
16 base::StringValue string_value_2("string value 2"); 17 base::StringValue string_value_2("string value 2");
17 base::DictionaryValue dictionary_value_1; 18 base::DictionaryValue dictionary_value_1;
18 dictionary_value_1.SetInteger("int value", 1); 19 dictionary_value_1.SetInteger("int value", 1);
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 "845EF34663FF8D32BE6707F40258FBA531C2BFC532E3B014AFB3476115C2A9DE"; 194 "845EF34663FF8D32BE6707F40258FBA531C2BFC532E3B014AFB3476115C2A9DE";
194 195
195 base::ListValue startup_urls; 196 base::ListValue startup_urls;
196 startup_urls.Set(0, new base::StringValue("http://www.chromium.org/")); 197 startup_urls.Set(0, new base::StringValue("http://www.chromium.org/"));
197 198
198 EXPECT_EQ( 199 EXPECT_EQ(
199 PrefHashCalculator::VALID_SECURE_LEGACY, 200 PrefHashCalculator::VALID_SECURE_LEGACY,
200 PrefHashCalculator(std::string(kSeed, arraysize(kSeed)), kDeviceId) 201 PrefHashCalculator(std::string(kSeed, arraysize(kSeed)), kDeviceId)
201 .Validate("session.startup_urls", &startup_urls, kExpectedValue)); 202 .Validate("session.startup_urls", &startup_urls, kExpectedValue));
202 } 203 }
OLDNEW
« no previous file with comments | « components/user_prefs/tracked/pref_hash_calculator.cc ('k') | components/user_prefs/tracked/pref_hash_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698