summaryrefslogtreecommitdiffstats
path: root/WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp
diff options
context:
space:
mode:
authorBen Murdoch <benm@google.com>2010-07-22 15:37:06 +0100
committerBen Murdoch <benm@google.com>2010-07-27 10:20:25 +0100
commit967717af5423377c967781471ee106e2bb4e11c8 (patch)
tree1e701dc0a12f7f07cce1df4a7681717de77a211b /WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp
parentdcc30a9fca45f634b1d3a12b276d3a0ccce99fc3 (diff)
downloadexternal_webkit-967717af5423377c967781471ee106e2bb4e11c8.zip
external_webkit-967717af5423377c967781471ee106e2bb4e11c8.tar.gz
external_webkit-967717af5423377c967781471ee106e2bb4e11c8.tar.bz2
Merge WebKit at r63859 : Initial merge by git.
Change-Id: Ie8096c63ec7c991c9a9cba8bdd9c3b74a3b8ed62
Diffstat (limited to 'WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp')
-rw-r--r--WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp25
1 files changed, 24 insertions, 1 deletions
diff --git a/WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp b/WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp
index 00b2d50..232c396 100644
--- a/WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp
+++ b/WebKitTools/WebKitTestRunner/win/TestControllerWin.cpp
@@ -25,13 +25,36 @@
#include "TestController.h"
+#include <fcntl.h>
+#include <io.h>
#include <WebKit2/WKStringCF.h>
namespace WTR {
+void TestController::platformInitialize()
+{
+ _setmode(1, _O_BINARY);
+ _setmode(2, _O_BINARY);
+}
+
void TestController::initializeInjectedBundlePath()
{
- // Implement
+ CFStringRef exeContainerPath = CFURLCopyFileSystemPath(CFURLCreateCopyDeletingLastPathComponent(0, CFBundleCopyExecutableURL(CFBundleGetMainBundle())), kCFURLWindowsPathStyle);
+ CFMutableStringRef bundlePath = CFStringCreateMutableCopy(0, 0, exeContainerPath);
+#ifndef NDEBUG
+ CFStringAppendCString(bundlePath, "\\InjectedBundle_debug.dll", kCFStringEncodingWindowsLatin1);
+#else
+ CFStringAppendCString(bundlePath, "\\InjectedBundle.dll", kCFStringEncodingWindowsLatin1);
+#endif
+
+ m_injectedBundlePath.adopt(WKStringCreateWithCFString(bundlePath));
+}
+
+void TestController::initializeTestPluginPath()
+{
+ CFStringRef exeContainerPath = CFURLCopyFileSystemPath(CFURLCreateCopyDeletingLastPathComponent(0, CFBundleCopyExecutableURL(CFBundleGetMainBundle())), kCFURLWindowsPathStyle);
+ CFMutableStringRef bundlePath = CFStringCreateMutableCopy(0, 0, exeContainerPath);
+ m_testPluginPath.adopt(WKStringCreateWithCFString(bundlePath));
}
} // namespace WTR