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

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

Issue 2675063002: Browser tests for using the new SafeBrowsing protocol (v4) (Closed)
Patch Set: Use ANNOTATE_LEAKING_OBJECT_PTR Created 3 years, 10 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/test_safe_browsing_service.cc
diff --git a/chrome/browser/safe_browsing/test_safe_browsing_service.cc b/chrome/browser/safe_browsing/test_safe_browsing_service.cc
index b836b18dec5c154330073c3c92b0fd9b87f05410..731a5ca667a341c1749985ff5d00eb151ccde585 100644
--- a/chrome/browser/safe_browsing/test_safe_browsing_service.cc
+++ b/chrome/browser/safe_browsing/test_safe_browsing_service.cc
@@ -10,12 +10,15 @@
#include "chrome/browser/safe_browsing/ui_manager.h"
#include "components/safe_browsing_db/database_manager.h"
#include "components/safe_browsing_db/test_database_manager.h"
+#include "components/safe_browsing_db/v4_feature_list.h"
namespace safe_browsing {
// TestSafeBrowsingService functions:
-TestSafeBrowsingService::TestSafeBrowsingService()
- : protocol_manager_delegate_disabled_(false),
+TestSafeBrowsingService::TestSafeBrowsingService(
+ V4FeatureList::V4UsageStatus v4_usage_status)
+ : SafeBrowsingService(v4_usage_status),
+ protocol_manager_delegate_disabled_(false),
serialized_download_report_(base::EmptyString()) {}
TestSafeBrowsingService::~TestSafeBrowsingService() {}
@@ -90,15 +93,18 @@ void TestSafeBrowsingService::SetV4ProtocolConfig(
}
// TestSafeBrowsingServiceFactory functions:
-TestSafeBrowsingServiceFactory::TestSafeBrowsingServiceFactory()
- : test_safe_browsing_service_(nullptr), test_protocol_config_(nullptr) {}
+TestSafeBrowsingServiceFactory::TestSafeBrowsingServiceFactory(
+ V4FeatureList::V4UsageStatus v4_usage_status)
+ : test_safe_browsing_service_(nullptr),
+ test_protocol_config_(nullptr),
+ v4_usage_status_(v4_usage_status) {}
TestSafeBrowsingServiceFactory::~TestSafeBrowsingServiceFactory() {}
SafeBrowsingService*
TestSafeBrowsingServiceFactory::CreateSafeBrowsingService() {
// Instantiate TestSafeBrowsingService.
- test_safe_browsing_service_ = new TestSafeBrowsingService();
+ test_safe_browsing_service_ = new TestSafeBrowsingService(v4_usage_status_);
// Plug-in test member clases accordingly.
if (test_ui_manager_)
test_safe_browsing_service_->SetUIManager(test_ui_manager_.get());
« no previous file with comments | « chrome/browser/safe_browsing/test_safe_browsing_service.h ('k') | components/safe_browsing_db/v4_database.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698