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

Unified Diff: chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc

Issue 1870003002: Convert //chrome/browser/safe_browsing from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and address comments Created 4 years, 8 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/safe_browsing/browser_feature_extractor_unittest.cc
diff --git a/chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc b/chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc
index 9f22e54325e2f72edec5efe9ebecdee0e0a1f996..121018b5d96ee35344a7429159ee15cee5e054b9 100644
--- a/chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc
+++ b/chrome/browser/safe_browsing/browser_feature_extractor_unittest.cc
@@ -5,11 +5,11 @@
#include "chrome/browser/safe_browsing/browser_feature_extractor.h"
#include <map>
+#include <memory>
#include <string>
#include <vector>
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "base/message_loop/message_loop.h"
#include "base/strings/stringprintf.h"
#include "base/time/time.h"
@@ -206,15 +206,15 @@ class BrowserFeatureExtractorTest : public ChromeRenderViewHostTestHarness {
}
int num_pending_; // Number of pending feature extractions.
- scoped_ptr<BrowserFeatureExtractor> extractor_;
+ std::unique_ptr<BrowserFeatureExtractor> extractor_;
std::map<void*, bool> success_;
- scoped_ptr<BrowseInfo> browse_info_;
- scoped_ptr<StrictMock<MockClientSideDetectionHost> > host_;
+ std::unique_ptr<BrowseInfo> browse_info_;
+ std::unique_ptr<StrictMock<MockClientSideDetectionHost>> host_;
scoped_refptr<StrictMock<MockSafeBrowsingDatabaseManager> > db_manager_;
private:
void ExtractFeaturesDone(bool success,
- scoped_ptr<ClientPhishingRequest> request) {
+ std::unique_ptr<ClientPhishingRequest> request) {
EXPECT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::UI));
ASSERT_EQ(0U, success_.count(request.get()));
// The pointer doesn't really belong to us. It belongs to
@@ -227,7 +227,7 @@ class BrowserFeatureExtractorTest : public ChromeRenderViewHostTestHarness {
void ExtractMalwareFeaturesDone(
bool success,
- scoped_ptr<ClientMalwareRequest> request) {
+ std::unique_ptr<ClientMalwareRequest> request) {
EXPECT_TRUE(BrowserThread::CurrentlyOn(BrowserThread::UI));
ASSERT_EQ(0U, success_.count(request.get()));
// The pointer doesn't really belong to us. It belongs to
« no previous file with comments | « chrome/browser/safe_browsing/browser_feature_extractor.cc ('k') | chrome/browser/safe_browsing/client_side_detection_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698