summaryrefslogtreecommitdiffstats
path: root/chrome_frame/test
diff options
context:
space:
mode:
authortommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-25 19:06:57 +0000
committertommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-25 19:06:57 +0000
commit76180ea4287b9458d97f8d547daf785bf136fba1 (patch)
treea8eeb50c3f486c330ea07530e1a77f126e195f55 /chrome_frame/test
parent64134fec4ed2f78dde84c6533dd2cc962f365ae6 (diff)
downloadchromium_src-76180ea4287b9458d97f8d547daf785bf136fba1.zip
chromium_src-76180ea4287b9458d97f8d547daf785bf136fba1.tar.gz
chromium_src-76180ea4287b9458d97f8d547daf785bf136fba1.tar.bz2
Load chrome.dll as a resource dll so that resources can be loaded by the browser.
TEST=fixes net tests for chrome frame BUG=none Review URL: http://codereview.chromium.org/437050 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33094 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/test')
-rw-r--r--chrome_frame/test/net/fake_external_tab.cc10
-rw-r--r--chrome_frame/test/net/fake_external_tab.h3
2 files changed, 11 insertions, 2 deletions
diff --git a/chrome_frame/test/net/fake_external_tab.cc b/chrome_frame/test/net/fake_external_tab.cc
index 5caadd33..cc31331 100644
--- a/chrome_frame/test/net/fake_external_tab.cc
+++ b/chrome_frame/test/net/fake_external_tab.cc
@@ -104,6 +104,15 @@ void FakeExternalTab::Initialize() {
chrome::RegisterPathProvider();
app::RegisterPathProvider();
+ // Load Chrome.dll as our resource dll.
+ FilePath dll;
+ PathService::Get(base::DIR_MODULE, &dll);
+ dll = dll.Append(chrome::kBrowserResourcesDll);
+ HMODULE res_mod = ::LoadLibraryExW(dll.value().c_str(),
+ NULL, LOAD_LIBRARY_AS_DATAFILE | LOAD_LIBRARY_AS_IMAGE_RESOURCE);
+ DCHECK(res_mod);
+ _AtlBaseModule.SetResourceInstance(res_mod);
+
ResourceBundle::InitSharedInstance(L"en-US");
const CommandLine* cmd = CommandLine::ForCurrentProcess();
@@ -339,6 +348,7 @@ void FilterDisabledTests() {
const char* disabled_tests[] = {
// Tests disabled since they're testing the same functionality used
// by the TestAutomationProvider.
+ "URLRequestTest.Intercept",
"URLRequestTest.InterceptNetworkError",
"URLRequestTest.InterceptRestartRequired",
"URLRequestTest.InterceptRespectsCancelMain",
diff --git a/chrome_frame/test/net/fake_external_tab.h b/chrome_frame/test/net/fake_external_tab.h
index bd67a7f..dd35756 100644
--- a/chrome_frame/test/net/fake_external_tab.h
+++ b/chrome_frame/test/net/fake_external_tab.h
@@ -24,7 +24,7 @@ class ProcessSingleton;
class FakeExternalTab {
public:
FakeExternalTab();
- ~FakeExternalTab();
+ virtual ~FakeExternalTab();
virtual std::wstring GetProfileName();
@@ -92,7 +92,6 @@ class CFUrlRequestUnittestRunner
protected:
ScopedHandle test_thread_;
DWORD test_thread_id_;
- scoped_ptr<MessageLoop> test_thread_message_loop_;
scoped_ptr<test_server::SimpleWebServer> test_http_server_;
test_server::SimpleResponse chrome_frame_html_;