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

Side by Side Diff: chrome/browser/safe_browsing/signature_evaluator_mac_unittest.cc

Issue 2733343002: Move chrome/common/safe_browsing/csd.proto to components/safe_browsing (Closed)
Patch Set: rebase again Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "chrome/browser/safe_browsing/signature_evaluator_mac.h" 5 #include "chrome/browser/safe_browsing/signature_evaluator_mac.h"
6 6
7 #include <CoreFoundation/CoreFoundation.h> 7 #include <CoreFoundation/CoreFoundation.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string.h> 9 #include <string.h>
10 #include <sys/xattr.h> 10 #include <sys/xattr.h>
11 11
12 #include <string> 12 #include <string>
13 #include <vector> 13 #include <vector>
14 14
15 #include "base/files/file_path.h" 15 #include "base/files/file_path.h"
16 #include "base/files/file_util.h" 16 #include "base/files/file_util.h"
17 #include "base/files/scoped_temp_dir.h" 17 #include "base/files/scoped_temp_dir.h"
18 #include "base/mac/scoped_cftyperef.h" 18 #include "base/mac/scoped_cftyperef.h"
19 #include "base/path_service.h" 19 #include "base/path_service.h"
20 #include "base/strings/sys_string_conversions.h" 20 #include "base/strings/sys_string_conversions.h"
21 #include "base/test/scoped_path_override.h" 21 #include "base/test/scoped_path_override.h"
22 #include "chrome/browser/safe_browsing/incident_reporting/incident.h" 22 #include "chrome/browser/safe_browsing/incident_reporting/incident.h"
23 #include "chrome/browser/safe_browsing/incident_reporting/mock_incident_receiver .h" 23 #include "chrome/browser/safe_browsing/incident_reporting/mock_incident_receiver .h"
24 #include "chrome/common/chrome_paths.h" 24 #include "chrome/common/chrome_paths.h"
25 #include "chrome/common/safe_browsing/csd.pb.h" 25 #include "components/safe_browsing/csd.pb.h"
26 #include "testing/gmock/include/gmock/gmock-matchers.h" 26 #include "testing/gmock/include/gmock/gmock-matchers.h"
27 #include "testing/gmock/include/gmock/gmock.h" 27 #include "testing/gmock/include/gmock/gmock.h"
28 #include "testing/gtest/include/gtest/gtest.h" 28 #include "testing/gtest/include/gtest/gtest.h"
29 29
30 using ::testing::_; 30 using ::testing::_;
31 using ::testing::StrictMock; 31 using ::testing::StrictMock;
32 32
33 namespace safe_browsing { 33 namespace safe_browsing {
34 34
35 namespace { 35 namespace {
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 std::vector<std::string> xattrs_seen; 328 std::vector<std::string> xattrs_seen;
329 for (const auto& xattr : mainmenunib->signature().xattr()) { 329 for (const auto& xattr : mainmenunib->signature().xattr()) {
330 ASSERT_TRUE(xattr.has_key()); 330 ASSERT_TRUE(xattr.has_key());
331 EXPECT_TRUE(xattr.has_value()); 331 EXPECT_TRUE(xattr.has_value());
332 xattrs_seen.push_back(xattr.key()); 332 xattrs_seen.push_back(xattr.key());
333 } 333 }
334 EXPECT_THAT(xattrs_known, ::testing::ContainerEq(xattrs_seen)); 334 EXPECT_THAT(xattrs_known, ::testing::ContainerEq(xattrs_seen));
335 } 335 }
336 336
337 } // namespace safe_browsing 337 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/signature_evaluator_mac.mm ('k') | chrome/browser/safe_browsing/threat_details.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698