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

Unified Diff: components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc

Issue 2698393002: Allow asynchronous deferral in NavigationSimulator (Closed)
Patch Set: clamy review 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 side-by-side diff with in-line comments
Download patch
Index: components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc
diff --git a/components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc b/components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc
index a2ffb3cb6c3b8362285803116be54c8b5045a558..ef48d0883258eccad611196e372e9740f3b7b1bc 100644
--- a/components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc
+++ b/components/subresource_filter/content/browser/content_subresource_filter_driver_factory_unittest.cc
@@ -241,7 +241,8 @@ class ContentSubresourceFilterDriverFactoryTest
navigation_chain.front(), main_rfh());
navigation_simulator->SetReferrer(referrer);
navigation_simulator->SetTransition(transition);
- navigation_simulator->Start();
+ EXPECT_EQ(content::NavigationThrottle::PROCEED,
+ navigation_simulator->Start());
if (blacklisted_urls.front()) {
factory()->OnMainResourceMatchedSafeBrowsingBlacklist(
@@ -256,10 +257,12 @@ class ContentSubresourceFilterDriverFactoryTest
factory()->OnMainResourceMatchedSafeBrowsingBlacklist(
url, navigation_chain, threat_type, threat_type_metadata);
}
- navigation_simulator->Redirect(url);
+ EXPECT_EQ(content::NavigationThrottle::PROCEED,
+ navigation_simulator->Redirect(url));
}
- navigation_simulator->Commit();
+ EXPECT_EQ(content::NavigationThrottle::PROCEED,
+ navigation_simulator->Commit());
ExpectActivationSignalForFrame(main_rfh(), expected_activation);
EXPECT_EQ(expected_activation_decision,
factory()->GetActivationDecisionForLastCommittedPageLoad());

Powered by Google App Engine
This is Rietveld 408576698