| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include <set> | 5 #include <set> |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 648 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 659 const std::string& status_text) { | 659 const std::string& status_text) { |
| 660 EXPECT_TRUE(PageContains("http://correction1/")); | 660 EXPECT_TRUE(PageContains("http://correction1/")); |
| 661 EXPECT_TRUE(PageContains("http://correction2/")); | 661 EXPECT_TRUE(PageContains("http://correction2/")); |
| 662 EXPECT_TRUE(PageContains(status_text)); | 662 EXPECT_TRUE(PageContains(status_text)); |
| 663 } | 663 } |
| 664 | 664 |
| 665 void DnsProbeBrowserTest::OnDnsProbeStatusSent( | 665 void DnsProbeBrowserTest::OnDnsProbeStatusSent( |
| 666 DnsProbeStatus dns_probe_status) { | 666 DnsProbeStatus dns_probe_status) { |
| 667 dns_probe_status_queue_.push_back(dns_probe_status); | 667 dns_probe_status_queue_.push_back(dns_probe_status); |
| 668 if (awaiting_dns_probe_status_) | 668 if (awaiting_dns_probe_status_) |
| 669 MessageLoop::current()->Quit(); | 669 MessageLoop::current()->QuitWhenIdle(); |
| 670 } | 670 } |
| 671 | 671 |
| 672 // Make sure probes don't break non-DNS error pages when corrections load. | 672 // Make sure probes don't break non-DNS error pages when corrections load. |
| 673 IN_PROC_BROWSER_TEST_F(DnsProbeBrowserTest, OtherErrorWithCorrectionsSuccess) { | 673 IN_PROC_BROWSER_TEST_F(DnsProbeBrowserTest, OtherErrorWithCorrectionsSuccess) { |
| 674 SetCorrectionServiceBroken(false); | 674 SetCorrectionServiceBroken(false); |
| 675 | 675 |
| 676 NavigateToOtherError(2); | 676 NavigateToOtherError(2); |
| 677 ExpectDisplayingCorrections("ERR_CONNECTION_REFUSED"); | 677 ExpectDisplayingCorrections("ERR_CONNECTION_REFUSED"); |
| 678 } | 678 } |
| 679 | 679 |
| (...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 989 | 989 |
| 990 EXPECT_EQ(error_page::DNS_PROBE_FINISHED_INCONCLUSIVE, | 990 EXPECT_EQ(error_page::DNS_PROBE_FINISHED_INCONCLUSIVE, |
| 991 WaitForSentStatus()); | 991 WaitForSentStatus()); |
| 992 EXPECT_EQ(0, pending_status_count()); | 992 EXPECT_EQ(0, pending_status_count()); |
| 993 ExpectDisplayingLocalErrorPage("ERR_NAME_NOT_RESOLVED"); | 993 ExpectDisplayingLocalErrorPage("ERR_NAME_NOT_RESOLVED"); |
| 994 } | 994 } |
| 995 | 995 |
| 996 } // namespace | 996 } // namespace |
| 997 | 997 |
| 998 } // namespace chrome_browser_net | 998 } // namespace chrome_browser_net |
| OLD | NEW |