diff options
| author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-05-07 11:21:11 +0200 |
|---|---|---|
| committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-05-07 11:21:11 +0200 |
| commit | 2cf6c8816a73e0132bd8fa3b509d62d7c51b6e47 (patch) | |
| tree | 988e8c5b116dd0466244ae2fe5af8ee9be926d76 /Tools/WebKitTestRunner/TestInvocation.cpp | |
| parent | dd91e772430dc294e3bf478c119ef8d43c0a3358 (diff) | |
| download | qtwebkit-2cf6c8816a73e0132bd8fa3b509d62d7c51b6e47.tar.gz | |
Imported WebKit commit 7e538425aa020340619e927792f3d895061fb54b (http://svn.webkit.org/repository/webkit/trunk@116286)
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) |
