diff options
Diffstat (limited to 'Tools/WebKitTestRunner/TestInvocation.cpp')
| -rw-r--r-- | Tools/WebKitTestRunner/TestInvocation.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Tools/WebKitTestRunner/TestInvocation.cpp b/Tools/WebKitTestRunner/TestInvocation.cpp index f6fb31126..e5ad9b6d1 100644 --- a/Tools/WebKitTestRunner/TestInvocation.cpp +++ b/Tools/WebKitTestRunner/TestInvocation.cpp @@ -37,6 +37,7 @@ #include <WebKit2/WKRetainPtr.h> #include <wtf/OwnArrayPtr.h> #include <wtf/PassOwnArrayPtr.h> +#include <wtf/text/CString.h> #if OS(WINDOWS) #include <direct.h> // For _getcwd. @@ -95,7 +96,6 @@ TestInvocation::TestInvocation(const std::string& pathOrURL) : m_url(AdoptWK, createWKURL(pathOrURL.c_str())) , m_pathOrURL(pathOrURL) , m_dumpPixels(false) - , m_skipPixelTestOption(false) , m_gotInitialResponse(false) , m_gotFinalMessage(false) , m_gotRepaint(false) @@ -109,8 +109,6 @@ TestInvocation::~TestInvocation() void TestInvocation::setIsPixelTest(const std::string& expectedPixelHash) { - if (m_skipPixelTestOption && !expectedPixelHash.length()) - return; m_dumpPixels = true; m_expectedPixelHash = expectedPixelHash; } @@ -162,8 +160,10 @@ void TestInvocation::invoke() return; } +#if ENABLE(INSPECTOR) if (shouldOpenWebInspector(m_pathOrURL.c_str())) WKInspectorShow(WKPageGetInspector(TestController::shared().mainWebView()->page())); +#endif // ENABLE(INSPECTOR) WKPageLoadURL(TestController::shared().mainWebView()->page(), m_url.get()); @@ -173,7 +173,9 @@ void TestInvocation::invoke() else if (m_error) dump("FAIL\n"); +#if ENABLE(INSPECTOR) WKInspectorClose(WKPageGetInspector(TestController::shared().mainWebView()->page())); +#endif // ENABLE(INSPECTOR) } void TestInvocation::dump(const char* stringToDump, bool singleEOF) @@ -242,7 +244,7 @@ void TestInvocation::didReceiveMessageFromInjectedBundle(WKStringRef messageName WKArrayRef repaintRects = static_cast<WKArrayRef>(WKDictionaryGetItemForKey(messageBodyDictionary, repaintRectsKey.get())); // Dump text. - dump(toSTD(textOutput).c_str(), true); + dump(toWTFString(textOutput).utf8().data(), true); // Dump pixels (if necessary). if (m_dumpPixels && pixelResult) |
