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

Unified Diff: net/proxy/proxy_script_decider_unittest.cc

Issue 962373002: ProxyScriptDecider: Fix NOTREACHED in Cancel() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« no previous file with comments | « net/proxy/proxy_script_decider.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/proxy/proxy_script_decider_unittest.cc
diff --git a/net/proxy/proxy_script_decider_unittest.cc b/net/proxy/proxy_script_decider_unittest.cc
index 8914f5beed50d265614ba675fbda760505922304..f26e5e194795e422ef84eb9392bcf034b9d235bc 100644
--- a/net/proxy/proxy_script_decider_unittest.cc
+++ b/net/proxy/proxy_script_decider_unittest.cc
@@ -428,6 +428,16 @@ TEST_F(ProxyScriptDeciderQuickCheckTest, ExplicitPacUrl) {
EXPECT_EQ(rule.url, decider_->effective_config().pac_url());
}
+// Regression test for http://crbug.com/409698.
+// This test lets the state machine get into state QUICK_CHECK_COMPLETE, then
+// destroys the decider, causing a cancel.
+TEST_F(ProxyScriptDeciderQuickCheckTest, CancelPartway) {
+ resolver_.set_synchronous_mode(false);
+ resolver_.set_ondemand_mode(true);
+ EXPECT_EQ(ERR_IO_PENDING, StartDecider());
+ decider_.reset(NULL);
+}
+
// Fails at WPAD (downloading), but succeeds in choosing the custom PAC.
TEST(ProxyScriptDeciderTest, AutodetectFailCustomSuccess1) {
Rules rules;
« no previous file with comments | « net/proxy/proxy_script_decider.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698