diff options
author | ananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-12 21:44:35 +0000 |
---|---|---|
committer | ananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-10-12 21:44:35 +0000 |
commit | b58dd3e18054fe1f1567f810114e8a84fa144a21 (patch) | |
tree | c4f2924d4d780930df26eb470823260a19422428 /chrome_frame/test | |
parent | 3ad28fc1dcf7ea1957f578c8362bb7a4b4f92d1e (diff) | |
download | chromium_src-b58dd3e18054fe1f1567f810114e8a84fa144a21.zip chromium_src-b58dd3e18054fe1f1567f810114e8a84fa144a21.tar.gz chromium_src-b58dd3e18054fe1f1567f810114e8a84fa144a21.tar.bz2 |
Fix the ChromeFrame net test failures. These tests started failing since the change to return
true from the AutomationResourceMessageFilter::OnMessageReceived for network request IPCs. ChromeFrame
net tests also have a AutomationResourceMessageFilter instance which is not registered as a
real message filter and is instead invoked from the TestAutomationProvider.
Fix is to remove the dummy AutomationResourceMessageFilter instance and instead register the
filter as a real message filter. To achieve this the automation_resource_message_filter_
member in the AutomationProvider class is now protected.
TBR=tommi
Review URL: http://codereview.chromium.org/3741001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62341 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/test')
-rw-r--r-- | chrome_frame/test/net/test_automation_provider.cc | 7 | ||||
-rw-r--r-- | chrome_frame/test/net/test_automation_provider.h | 1 |
2 files changed, 4 insertions, 4 deletions
diff --git a/chrome_frame/test/net/test_automation_provider.cc b/chrome_frame/test/net/test_automation_provider.cc index ef5528a..db89bc2 100644 --- a/chrome_frame/test/net/test_automation_provider.cc +++ b/chrome_frame/test/net/test_automation_provider.cc @@ -38,7 +38,8 @@ TestAutomationProvider::TestAutomationProvider( TestAutomationProvider::Factory); URLRequest::RegisterProtocolFactory("https", TestAutomationProvider::Factory); - filter_ = new TestAutomationResourceMessageFilter(this); + automation_resource_message_filter_ = + new TestAutomationResourceMessageFilter(this); g_provider_instance_ = this; } @@ -47,7 +48,7 @@ TestAutomationProvider::~TestAutomationProvider() { } void TestAutomationProvider::OnMessageReceived(const IPC::Message& msg) { - if (filter_->OnMessageReceived(msg)) + if (automation_resource_message_filter_->OnMessageReceived(msg)) return; // Message handled by the filter. __super::OnMessageReceived(msg); @@ -89,7 +90,7 @@ URLRequestJob* TestAutomationProvider::Factory(URLRequest* request, static int new_id = 0x00100000; URLRequestAutomationJob* job = new URLRequestAutomationJob(request, g_provider_instance_->tab_handle_, new_id++, - g_provider_instance_->filter_, false); + g_provider_instance_->automation_resource_message_filter_, false); return job; } } diff --git a/chrome_frame/test/net/test_automation_provider.h b/chrome_frame/test/net/test_automation_provider.h index 9e52b3b..d462108 100644 --- a/chrome_frame/test/net/test_automation_provider.h +++ b/chrome_frame/test/net/test_automation_provider.h @@ -47,7 +47,6 @@ class TestAutomationProvider TestAutomationProviderDelegate* delegate); protected: - scoped_refptr<TestAutomationResourceMessageFilter> filter_; int tab_handle_; TestAutomationProviderDelegate* delegate_; |