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

Side by Side Diff: components/packed_ct_ev_whitelist/packed_ct_ev_whitelist_unittest.cc

Issue 1551433002: Switch to standard integer types in components/, part 3 of 4. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/packed_ct_ev_whitelist/packed_ct_ev_whitelist.h" 5 #include "components/packed_ct_ev_whitelist/packed_ct_ev_whitelist.h"
6 6
7 #include <stdint.h>
8
7 #include <algorithm> 9 #include <algorithm>
8 #include <string> 10 #include <string>
9 11
10 #include "base/big_endian.h" 12 #include "base/big_endian.h"
13 #include "base/macros.h"
11 #include "testing/gtest/include/gtest/gtest.h" 14 #include "testing/gtest/include/gtest/gtest.h"
12 15
13 namespace { 16 namespace {
14 17
15 const uint8_t kFirstHashRaw[] = 18 const uint8_t kFirstHashRaw[] =
16 {0x00, 0x00, 0x03, 0xd7, 0xfc, 0x18, 0x02, 0xcb}; 19 {0x00, 0x00, 0x03, 0xd7, 0xfc, 0x18, 0x02, 0xcb};
17 std::string GetFirstHash() { 20 std::string GetFirstHash() {
18 return std::string(reinterpret_cast<const char*>(kFirstHashRaw), 8); 21 return std::string(reinterpret_cast<const char*>(kFirstHashRaw), 8);
19 } 22 }
20 23
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 } 148 }
146 149
147 TEST(PackedEVCertsWhitelistTest, CorrectlyIdentifiesWhitelistIsValid) { 150 TEST(PackedEVCertsWhitelistTest, CorrectlyIdentifiesWhitelistIsValid) {
148 scoped_refptr<PackedEVCertsWhitelist> whitelist( 151 scoped_refptr<PackedEVCertsWhitelist> whitelist(
149 new PackedEVCertsWhitelist(GetAllWhitelistData(), base::Version())); 152 new PackedEVCertsWhitelist(GetAllWhitelistData(), base::Version()));
150 153
151 EXPECT_TRUE(whitelist->IsValid()); 154 EXPECT_TRUE(whitelist->IsValid());
152 } 155 }
153 156
154 } // namespace packed_ct_ev_whitelist 157 } // namespace packed_ct_ev_whitelist
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698