Index: chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc |
diff --git a/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc b/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc |
index a776e193e2196cc60e98e6cf99c7ce45db11152a..2ae08d3f0c145048729ee0768b0cf58d9f0c5a02 100644 |
--- a/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc |
+++ b/chrome/browser/safe_browsing/incident_reporting/binary_integrity_analyzer_mac_unittest.cc |
@@ -6,11 +6,12 @@ |
#include <stdint.h> |
+#include <memory> |
+ |
#include "base/files/file.h" |
#include "base/files/file_util.h" |
#include "base/files/scoped_temp_dir.h" |
#include "base/mac/bundle_locations.h" |
-#include "base/memory/scoped_ptr.h" |
#include "base/path_service.h" |
#include "chrome/browser/safe_browsing/incident_reporting/incident.h" |
#include "chrome/browser/safe_browsing/incident_reporting/mock_incident_receiver.h" |
@@ -91,14 +92,14 @@ TEST_F(BinaryIntegrityAnalyzerMacTest, GetCriticalPathsAndRequirements) { |
} |
TEST_F(BinaryIntegrityAnalyzerMacTest, VerifyBinaryIntegrityForTesting) { |
- scoped_ptr<MockIncidentReceiver> mock_receiver( |
+ std::unique_ptr<MockIncidentReceiver> mock_receiver( |
new StrictMock<MockIncidentReceiver>()); |
base::FilePath bundle = temp_dir_.path().Append(kBundleBase); |
std::string requirement( |
"certificate leaf[subject.CN]=\"untrusted@goat.local\""); |
// Run check on valid bundle. |
- scoped_ptr<Incident> incident_to_clear; |
+ std::unique_ptr<Incident> incident_to_clear; |
EXPECT_CALL(*mock_receiver, DoClearIncidentForProcess(_)) |
.WillOnce(TakeIncident(&incident_to_clear)); |
VerifyBinaryIntegrityForTesting(mock_receiver.get(), bundle, requirement); |
@@ -110,14 +111,14 @@ TEST_F(BinaryIntegrityAnalyzerMacTest, VerifyBinaryIntegrityForTesting) { |
base::FilePath exe_path = temp_dir_.path().Append(kBundleURL); |
ASSERT_TRUE(CorruptFileContent(exe_path)); |
- scoped_ptr<Incident> incident; |
+ std::unique_ptr<Incident> incident; |
EXPECT_CALL(*mock_receiver, DoAddIncidentForProcess(_)) |
.WillOnce(TakeIncident(&incident)); |
VerifyBinaryIntegrityForTesting(mock_receiver.get(), bundle, requirement); |
// Verify that the incident report contains the expected data. |
- scoped_ptr<ClientIncidentReport_IncidentData> incident_data( |
+ std::unique_ptr<ClientIncidentReport_IncidentData> incident_data( |
incident->TakePayload()); |
ASSERT_TRUE(incident_data->has_binary_integrity()); |