diff options
Diffstat (limited to 'chrome/browser/safe_browsing')
-rw-r--r-- | chrome/browser/safe_browsing/malware_details_unittest.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/chrome/browser/safe_browsing/malware_details_unittest.cc b/chrome/browser/safe_browsing/malware_details_unittest.cc index 85b2d45..b6136c8 100644 --- a/chrome/browser/safe_browsing/malware_details_unittest.cc +++ b/chrome/browser/safe_browsing/malware_details_unittest.cc @@ -94,7 +94,8 @@ TEST_F(MalwareDetailsTest, MalwareSubResource) { SafeBrowsingService::UnsafeResource resource; InitResource(&resource, ResourceType::SUB_RESOURCE, GURL(kMalwareURL)); - MalwareDetails* report = new MalwareDetails(contents(), resource); + scoped_refptr<MalwareDetails> report = new MalwareDetails( + contents(), resource); scoped_ptr<const std::string> serialized(report->GetSerializedReport()); safe_browsing::ClientMalwareReportRequest actual; @@ -123,7 +124,8 @@ TEST_F(MalwareDetailsTest, MalwareSubResourceWithOriginalUrl) { InitResource(&resource, ResourceType::SUB_RESOURCE, GURL(kMalwareURL)); resource.original_url = GURL(kOriginalLandingURL); - MalwareDetails* report = new MalwareDetails(contents(), resource); + scoped_refptr<MalwareDetails> report = new MalwareDetails( + contents(), resource); scoped_ptr<const std::string> serialized(report->GetSerializedReport()); safe_browsing::ClientMalwareReportRequest actual; @@ -154,7 +156,8 @@ TEST_F(MalwareDetailsTest, NotPublicUrl) { controller().LoadURL(GURL(kHttpsURL), GURL(), PageTransition::TYPED); SafeBrowsingService::UnsafeResource resource; InitResource(&resource, ResourceType::SUB_RESOURCE, GURL(kMalwareURL)); - MalwareDetails* report = new MalwareDetails(contents(), resource); + scoped_refptr<MalwareDetails> report = new MalwareDetails( + contents(), resource); scoped_ptr<const std::string> serialized(report->GetSerializedReport()); safe_browsing::ClientMalwareReportRequest actual; |