summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
Diffstat (limited to 'webkit')
-rw-r--r--webkit/glue/chrome_client_impl.cc8
-rw-r--r--webkit/glue/context_menu_unittest.cc9
-rw-r--r--webkit/glue/dom_operations_unittest.cc32
-rw-r--r--webkit/glue/dom_serializer_unittest.cc50
-rw-r--r--webkit/glue/iframe_redirect_unittest.cc9
-rw-r--r--webkit/glue/plugins/plugin_host.cc4
-rw-r--r--webkit/glue/resource_handle_impl.cc2
-rw-r--r--webkit/glue/resource_loader_bridge.h5
-rw-r--r--webkit/glue/weburlrequest_impl.cc5
-rw-r--r--webkit/glue/webview_delegate.h1
-rw-r--r--webkit/tools/test_shell/simple_resource_loader_bridge.cc2
-rw-r--r--webkit/tools/test_shell/test_shell_gtk.cc2
-rw-r--r--webkit/tools/test_shell/test_shell_test.cc14
-rw-r--r--webkit/tools/test_shell/test_shell_test.h9
14 files changed, 83 insertions, 69 deletions
diff --git a/webkit/glue/chrome_client_impl.cc b/webkit/glue/chrome_client_impl.cc
index 02e891d..bfa6db4 100644
--- a/webkit/glue/chrome_client_impl.cc
+++ b/webkit/glue/chrome_client_impl.cc
@@ -52,17 +52,17 @@ class WebFileChooserCallbackImpl : public WebFileChooserCallback {
: file_chooser_(file_chooser) {
}
- void OnFileChoose(const std::vector<std::wstring>& file_names) {
+ virtual void OnFileChoose(const std::vector<FilePath>& file_names) {
if (file_names.empty()) {
file_chooser_->chooseFile(WebCore::String(""));
} else if (file_names.size() == 1) {
file_chooser_->chooseFile(
- webkit_glue::StdWStringToString(file_names.front()));
+ webkit_glue::FilePathStringToString(file_names.front().value()));
} else {
Vector<WebCore::String> paths;
- for (std::vector<std::wstring>::const_iterator filename =
+ for (std::vector<FilePath>::const_iterator filename =
file_names.begin(); filename != file_names.end(); ++filename) {
- paths.append(webkit_glue::StdWStringToString(*filename));
+ paths.append(webkit_glue::FilePathStringToString((*filename).value()));
}
file_chooser_->chooseFiles(paths);
}
diff --git a/webkit/glue/context_menu_unittest.cc b/webkit/glue/context_menu_unittest.cc
index b7ff8ed..8e62c2c 100644
--- a/webkit/glue/context_menu_unittest.cc
+++ b/webkit/glue/context_menu_unittest.cc
@@ -7,6 +7,7 @@
#include <vector>
+#include "base/file_path.h"
#include "base/file_util.h"
#include "base/message_loop.h"
#include "webkit/glue/webframe.h"
@@ -24,12 +25,12 @@ class ContextMenuCapturing : public TestShellTest {
TestShellTest::SetUp();
iframes_data_dir_ = data_dir_;
- file_util::AppendToPath(&iframes_data_dir_, L"test_shell");
- file_util::AppendToPath(&iframes_data_dir_, L"iframes");
+ iframes_data_dir_ = iframes_data_dir_.AppendASCII("test_shell");
+ iframes_data_dir_ = iframes_data_dir_.AppendASCII("iframes");
ASSERT_TRUE(file_util::PathExists(iframes_data_dir_));
}
- std::wstring iframes_data_dir_;
+ FilePath iframes_data_dir_;
};
@@ -40,7 +41,7 @@ TEST_F(ContextMenuCapturing, ContextMenuCapturing) {
test_delegate->clear_captured_context_menu_events();
EXPECT_EQ(0U, test_delegate->captured_context_menu_events().size());
- std::wstring test_url = GetTestURL(iframes_data_dir_, L"testiframe.html");
+ std::wstring test_url = GetTestURL(iframes_data_dir_, "testiframe.html");
test_shell_->LoadURL(test_url.c_str());
test_shell_->WaitTestFinished();
diff --git a/webkit/glue/dom_operations_unittest.cc b/webkit/glue/dom_operations_unittest.cc
index e960375..0ebf1b4 100644
--- a/webkit/glue/dom_operations_unittest.cc
+++ b/webkit/glue/dom_operations_unittest.cc
@@ -20,7 +20,7 @@ class DomOperationsTests : public TestShellTest {
// Test function GetAllSavableResourceLinksForCurrentPage with a web page.
// We expect result of GetAllSavableResourceLinksForCurrentPage exactly
// matches expected_resources_set.
- void GetSavableResourceLinksForPage(const std::wstring& page_file_path,
+ void GetSavableResourceLinksForPage(const FilePath& page_file_path,
const std::set<GURL>& expected_resources_set);
protected:
@@ -36,7 +36,7 @@ class DomOperationsTests : public TestShellTest {
void DomOperationsTests::GetSavableResourceLinksForPage(
- const std::wstring& page_file_path,
+ const FilePath& page_file_path,
const std::set<GURL>& expected_resources_set) {
// Convert local file path to file URL.
GURL file_url = net::FilePathToFileURL(page_file_path);
@@ -75,30 +75,29 @@ void DomOperationsTests::GetSavableResourceLinksForPage(
TEST_F(DomOperationsTests, GetSavableResourceLinksWithPageHasValidLinks) {
std::set<GURL> expected_resources_set;
// Set directory of test data.
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer");
+ FilePath page_file_path = data_dir_.AppendASCII("dom_serializer");
const char* expected_sub_resource_links[] = {
"file:///c:/yt/css/base_all-vfl36460.css",
"file:///c:/yt/js/base_all_with_bidi-vfl36451.js",
"file:///c:/yt/img/pixel-vfl73.gif"
};
- const wchar_t* expected_frame_links[] = {
- L"youtube_1.htm",
- L"youtube_2.htm"
+ const char* expected_frame_links[] = {
+ "youtube_1.htm",
+ "youtube_2.htm"
};
// Add all expected links of sub-resource to expected set.
for (size_t i = 0; i < arraysize(expected_sub_resource_links); ++i)
expected_resources_set.insert(GURL(expected_sub_resource_links[i]));
// Add all expected links of frame to expected set.
for (size_t i = 0; i < arraysize(expected_frame_links); ++i) {
- std::wstring expected_frame_url = page_file_path;
- file_util::AppendToPath(&expected_frame_url, expected_frame_links[i]);
+ const FilePath expected_frame_url =
+ page_file_path.AppendASCII(expected_frame_links[i]);
expected_resources_set.insert(
net::FilePathToFileURL(expected_frame_url));
}
- file_util::AppendToPath(&page_file_path, std::wstring(L"youtube_1.htm"));
+ page_file_path = page_file_path.AppendASCII("youtube_1.htm");
GetSavableResourceLinksForPage(page_file_path, expected_resources_set);
}
@@ -107,21 +106,20 @@ TEST_F(DomOperationsTests, GetSavableResourceLinksWithPageHasValidLinks) {
TEST_F(DomOperationsTests, GetSavableResourceLinksWithPageHasInvalidLinks) {
std::set<GURL> expected_resources_set;
// Set directory of test data.
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer");
+ FilePath page_file_path = data_dir_.AppendASCII("dom_serializer");
- const wchar_t* expected_frame_links[] = {
- L"youtube_2.htm"
+ const char* expected_frame_links[] = {
+ "youtube_2.htm"
};
// Add all expected links of frame to expected set.
for (size_t i = 0; i < arraysize(expected_frame_links); ++i) {
- std::wstring expected_frame_url = page_file_path;
- file_util::AppendToPath(&expected_frame_url, expected_frame_links[i]);
+ FilePath expected_frame_url =
+ page_file_path.AppendASCII(expected_frame_links[i]);
expected_resources_set.insert(
net::FilePathToFileURL(expected_frame_url));
}
- file_util::AppendToPath(&page_file_path, std::wstring(L"youtube_2.htm"));
+ page_file_path = page_file_path.AppendASCII("youtube_2.htm");
GetSavableResourceLinksForPage(page_file_path, expected_resources_set);
}
diff --git a/webkit/glue/dom_serializer_unittest.cc b/webkit/glue/dom_serializer_unittest.cc
index 03afe5b..34a04a8 100644
--- a/webkit/glue/dom_serializer_unittest.cc
+++ b/webkit/glue/dom_serializer_unittest.cc
@@ -238,8 +238,9 @@ bool IsMetaElement(const WebCore::Node* node, WebCore::String* charset_info) {
// If original contents have document type, the serialized contents also have
// document type.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithDocType) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/youtube_1.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("youtube_1.htm");
GURL file_url = net::FilePathToFileURL(page_file_path);
ASSERT_TRUE(file_url.SchemeIsFile());
// Load the test file.
@@ -269,8 +270,9 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithDocType) {
// If original contents do not have document type, the serialized contents
// also do not have document type.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithoutDocType) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/youtube_2.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("youtube_2.htm");
GURL file_url = net::FilePathToFileURL(page_file_path);
ASSERT_TRUE(file_url.SchemeIsFile());
// Load the test file.
@@ -301,8 +303,9 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithoutDocType) {
// finishing serialization, the serialized contents should be same
// with original XML document.
TEST_F(DomSerializerTests, SerialzeXMLDocWithBuiltInEntities) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/note.xml");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("note.xml");
// Read original contents for later comparison.
std::string orginal_contents;
ASSERT_TRUE(file_util::ReadFileToString(page_file_path, &orginal_contents));
@@ -322,8 +325,9 @@ TEST_F(DomSerializerTests, SerialzeXMLDocWithBuiltInEntities) {
// When serializing DOM, we add MOTW declaration before html tag.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithAddingMOTW) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/youtube_2.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("youtube_2.htm");
// Read original contents for later comparison .
std::string orginal_contents;
ASSERT_TRUE(file_util::ReadFileToString(page_file_path, &orginal_contents));
@@ -355,8 +359,9 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithAddingMOTW) {
// http://bugs.webkit.org/show_bug.cgi?id=16621 even the original document
// does not have META charset declaration.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithNoMetaCharsetInOriginalDoc) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/youtube_1.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("youtube_1.htm");
// Get file URL.
GURL file_url = net::FilePathToFileURL(page_file_path);
ASSERT_TRUE(file_url.SchemeIsFile());
@@ -417,8 +422,9 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithNoMetaCharsetInOriginalDoc) {
// declarations.
TEST_F(DomSerializerTests,
SerialzeHTMLDOMWithMultipleMetaCharsetInOriginalDoc) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path, L"dom_serializer/youtube_2.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("youtube_2.htm");
// Get file URL.
GURL file_url = net::FilePathToFileURL(page_file_path);
ASSERT_TRUE(file_url.SchemeIsFile());
@@ -480,9 +486,9 @@ TEST_F(DomSerializerTests,
// Test situation of html entities in text when serializing HTML DOM.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithEntitiesInText) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path,
- L"dom_serializer/htmlentities_in_text.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path = page_file_path.AppendASCII("htmlentities_in_text.htm");
// Read original contents for later comparison .
std::string orginal_contents;
ASSERT_TRUE(file_util::ReadFileToString(page_file_path, &orginal_contents));
@@ -520,9 +526,10 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithEntitiesInText) {
// Test situation of html entities in attribute value when serializing
// HTML DOM.
TEST_F(DomSerializerTests, SerialzeHTMLDOMWithEntitiesInAttributeValue) {
- std::wstring page_file_path = data_dir_;
- file_util::AppendToPath(&page_file_path,
- L"dom_serializer/htmlentities_in_attribute_value.htm");
+ FilePath page_file_path = data_dir_;
+ page_file_path = page_file_path.AppendASCII("dom_serializer");
+ page_file_path =
+ page_file_path.AppendASCII("htmlentities_in_attribute_value.htm");
// Read original contents for later comparison.
std::string orginal_contents;
ASSERT_TRUE(file_util::ReadFileToString(page_file_path, &orginal_contents));
@@ -565,17 +572,16 @@ TEST_F(DomSerializerTests, SerialzeHTMLDOMWithBaseTag) {
// There are total 2 available base tags in this test file.
const int kTotalBaseTagCountInTestFile = 2;
- FilePath page_file_path = FilePath::FromWStringHack(data_dir_).AppendASCII(
- "dom_serializer");
+ FilePath page_file_path = data_dir_.AppendASCII("dom_serializer");
file_util::EnsureEndsWithSeparator(&page_file_path);
// Get page dir URL which is base URL of this file.
- GURL path_dir_url = net::FilePathToFileURL(page_file_path.ToWStringHack());
+ GURL path_dir_url = net::FilePathToFileURL(page_file_path);
// Get file path.
page_file_path =
page_file_path.AppendASCII("html_doc_has_base_tag.htm");
// Get file URL.
- GURL file_url = net::FilePathToFileURL(page_file_path.ToWStringHack());
+ GURL file_url = net::FilePathToFileURL(page_file_path);
ASSERT_TRUE(file_url.SchemeIsFile());
// Load the test file.
LoadPageFromURL(file_url);
diff --git a/webkit/glue/iframe_redirect_unittest.cc b/webkit/glue/iframe_redirect_unittest.cc
index 37be9a5..dc280e2 100644
--- a/webkit/glue/iframe_redirect_unittest.cc
+++ b/webkit/glue/iframe_redirect_unittest.cc
@@ -21,13 +21,12 @@ typedef TestShellTest IFrameRedirectTest;
// Tests that loading a page in an iframe from javascript results in
// a redirect from about:blank.
TEST_F(IFrameRedirectTest, Test) {
- std::wstring iframes_data_dir_ = data_dir_;
-
- file_util::AppendToPath(&iframes_data_dir_, L"test_shell");
- file_util::AppendToPath(&iframes_data_dir_, L"iframe_redirect");
+ FilePath iframes_data_dir_ = data_dir_;
+ iframes_data_dir_ = iframes_data_dir_.AppendASCII("test_shell");
+ iframes_data_dir_ = iframes_data_dir_.AppendASCII("iframe_redirect");
ASSERT_TRUE(file_util::PathExists(iframes_data_dir_));
- std::wstring test_url = GetTestURL(iframes_data_dir_, L"main.html");
+ std::wstring test_url = GetTestURL(iframes_data_dir_, "main.html");
test_shell_->LoadURL(test_url.c_str());
test_shell_->WaitTestFinished();
diff --git a/webkit/glue/plugins/plugin_host.cc b/webkit/glue/plugins/plugin_host.cc
index b87160a..bfefd0b 100644
--- a/webkit/glue/plugins/plugin_host.cc
+++ b/webkit/glue/plugins/plugin_host.cc
@@ -450,7 +450,9 @@ static NPError PostURLNotify(NPP id,
if (StartsWithASCII(file_path_ascii, kFileUrlPrefix, false)) {
GURL file_url(file_path_ascii);
DCHECK(file_url.SchemeIsFile());
- net::FileURLToFilePath(file_url, &file_path);
+ FilePath path;
+ net::FileURLToFilePath(file_url, &path);
+ file_path = path.ToWStringHack();
} else {
file_path = base::SysNativeMBToWide(file_path_ascii);
}
diff --git a/webkit/glue/resource_handle_impl.cc b/webkit/glue/resource_handle_impl.cc
index 523a293..7b1e6a3 100644
--- a/webkit/glue/resource_handle_impl.cc
+++ b/webkit/glue/resource_handle_impl.cc
@@ -451,7 +451,7 @@ bool ResourceHandleInternal::Start(
}
} else {
bridge_->AppendFileToUpload(
- webkit_glue::StringToStdWString(e.m_filename));
+ FilePath(webkit_glue::StringToFilePathString(e.m_filename)));
}
}
bridge_->SetUploadIdentifier(request_.httpBody()->identifier());
diff --git a/webkit/glue/resource_loader_bridge.h b/webkit/glue/resource_loader_bridge.h
index 07508d5..f006974 100644
--- a/webkit/glue/resource_loader_bridge.h
+++ b/webkit/glue/resource_loader_bridge.h
@@ -21,6 +21,7 @@
#if defined(OS_POSIX)
#include "base/file_descriptor_posix.h"
#endif
+#include "base/file_path.h"
#include "base/platform_file.h"
#include "base/ref_counted.h"
#include "base/time.h"
@@ -192,13 +193,13 @@ class ResourceLoaderBridge {
// Call this method before calling Start() to append the contents of a file
// to the request body. May only be used with HTTP(S) POST requests.
- void AppendFileToUpload(const std::wstring& file_path) {
+ void AppendFileToUpload(const FilePath& file_path) {
AppendFileRangeToUpload(file_path, 0, kuint64max);
}
// Call this method before calling Start() to append the contents of a file
// to the request body. May only be used with HTTP(S) POST requests.
- virtual void AppendFileRangeToUpload(const std::wstring& file_path,
+ virtual void AppendFileRangeToUpload(const FilePath& file_path,
uint64 offset, uint64 length) = 0;
// Call this method before calling Start() to assign an upload identifier to
diff --git a/webkit/glue/weburlrequest_impl.cc b/webkit/glue/weburlrequest_impl.cc
index cf30f7e3..655eb0f 100644
--- a/webkit/glue/weburlrequest_impl.cc
+++ b/webkit/glue/weburlrequest_impl.cc
@@ -172,7 +172,8 @@ void WebRequestImpl::GetUploadData(net::UploadData* data) const {
if (element.m_type == WebCore::FormDataElement::data) {
data->AppendBytes(element.m_data.data(), element.m_data.size());
} else if (element.m_type == WebCore::FormDataElement::encodedFile) {
- data->AppendFile(webkit_glue::StringToStdWString(element.m_filename));
+ data->AppendFile(
+ FilePath(webkit_glue::StringToFilePathString(element.m_filename)));
} else {
NOTREACHED();
}
@@ -195,7 +196,7 @@ void WebRequestImpl::SetUploadData(const net::UploadData& data)
element.bytes().size());
} else if (element.type() == net::UploadData::TYPE_FILE) {
formdata->appendFile(
- webkit_glue::StdWStringToString(element.file_path()));
+ webkit_glue::FilePathStringToString(element.file_path().value()));
} else {
NOTREACHED();
}
diff --git a/webkit/glue/webview_delegate.h b/webkit/glue/webview_delegate.h
index 03e1a78..c206ef8 100644
--- a/webkit/glue/webview_delegate.h
+++ b/webkit/glue/webview_delegate.h
@@ -28,6 +28,7 @@
#include <vector>
+#include "base/file_path.h"
#include "webkit/glue/context_menu.h"
#include "webkit/glue/webdatasource.h"
#include "webkit/glue/webwidget_delegate.h"
diff --git a/webkit/tools/test_shell/simple_resource_loader_bridge.cc b/webkit/tools/test_shell/simple_resource_loader_bridge.cc
index 755a6f6..fd409a0 100644
--- a/webkit/tools/test_shell/simple_resource_loader_bridge.cc
+++ b/webkit/tools/test_shell/simple_resource_loader_bridge.cc
@@ -456,7 +456,7 @@ class ResourceLoaderBridgeImpl : public ResourceLoaderBridge {
params_->upload->AppendBytes(data, data_len);
}
- virtual void AppendFileRangeToUpload(const std::wstring& file_path,
+ virtual void AppendFileRangeToUpload(const FilePath& file_path,
uint64 offset, uint64 length) {
DCHECK(params_.get());
if (!params_->upload)
diff --git a/webkit/tools/test_shell/test_shell_gtk.cc b/webkit/tools/test_shell/test_shell_gtk.cc
index 7083d7c..1041bdd 100644
--- a/webkit/tools/test_shell/test_shell_gtk.cc
+++ b/webkit/tools/test_shell/test_shell_gtk.cc
@@ -570,7 +570,7 @@ void TestShell::LoadURLForFrame(const wchar_t* url,
// PathExists will reject any string with no leading '/'
// as well as empty strings.
if (file_util::AbsolutePath(&path))
- gurl = net::FilePathToFileURL(path);
+ gurl = net::FilePathToFileURL(FilePath::FromWStringHack(path));
else
gurl = GURL(WideToUTF8(url));
diff --git a/webkit/tools/test_shell/test_shell_test.cc b/webkit/tools/test_shell/test_shell_test.cc
index 1ce279a..c6e7ac4 100644
--- a/webkit/tools/test_shell/test_shell_test.cc
+++ b/webkit/tools/test_shell/test_shell_test.cc
@@ -4,16 +4,18 @@
#include "webkit/tools/test_shell/test_shell_test.h"
+#include <string>
+
#include "base/basictypes.h"
+#include "base/file_path.h"
#include "base/file_util.h"
#include "base/message_loop.h"
#include "base/path_service.h"
#include "base/string_util.h"
-std::wstring TestShellTest::GetTestURL(std::wstring test_case_path,
- const std::wstring& test_case) {
- file_util::AppendToPath(&test_case_path, test_case);
- return test_case_path;
+std::wstring TestShellTest::GetTestURL(const FilePath& test_case_path,
+ const std::string& test_case) {
+ return test_case_path.AppendASCII(test_case).ToWStringHack();
}
void TestShellTest::SetUp() {
@@ -23,8 +25,8 @@ void TestShellTest::SetUp() {
// Point data_dir_ to the root of the test case dir
ASSERT_TRUE(PathService::Get(base::DIR_SOURCE_ROOT, &data_dir_));
- file_util::AppendToPath(&data_dir_, L"webkit");
- file_util::AppendToPath(&data_dir_, L"data");
+ data_dir_ = data_dir_.Append(FILE_PATH_LITERAL("webkit"));
+ data_dir_ = data_dir_.Append(FILE_PATH_LITERAL("data"));
ASSERT_TRUE(file_util::PathExists(data_dir_));
}
diff --git a/webkit/tools/test_shell/test_shell_test.h b/webkit/tools/test_shell/test_shell_test.h
index 2cdd792..4e6372b 100644
--- a/webkit/tools/test_shell/test_shell_test.h
+++ b/webkit/tools/test_shell/test_shell_test.h
@@ -10,6 +10,9 @@
#ifndef WEBKIT_TOOLS_TEST_SHELL_TEST_SHELL_TEST_H__
#define WEBKIT_TOOLS_TEST_SHELL_TEST_SHELL_TEST_H__
+#include <string>
+
+#include "base/file_path.h"
#include "webkit/glue/window_open_disposition.h"
#include "webkit/tools/test_shell/test_shell.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -17,8 +20,8 @@
class TestShellTest : public testing::Test {
protected:
// Returns the path "test_case_path/test_case".
- std::wstring GetTestURL(std::wstring test_case_path,
- const std::wstring& test_case);
+ std::wstring GetTestURL(const FilePath& test_case_path,
+ const std::string& test_case);
virtual void SetUp();
virtual void TearDown();
@@ -30,7 +33,7 @@ class TestShellTest : public testing::Test {
protected:
// Location of SOURCE_ROOT/webkit/data/
- std::wstring data_dir_;
+ FilePath data_dir_;
TestShell* test_shell_;
};