diff options
| author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-06-01 10:36:58 +0200 |
|---|---|---|
| committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-06-01 10:36:58 +0200 |
| commit | b1e9e47fa11f608ae16bc07f97a2acf95bf80272 (patch) | |
| tree | c88c45e80c9c44506e7cdf9a3bb39ebf82a8cd5b /Tools/WebKitTestRunner | |
| parent | be01689f43cf6882cf670d33df49ead1f570c53a (diff) | |
| download | qtwebkit-b1e9e47fa11f608ae16bc07f97a2acf95bf80272.tar.gz | |
Imported WebKit commit 499c84c99aa98e9870fa7eaa57db476c6d160d46 (http://svn.webkit.org/repository/webkit/trunk@119200)
Weekly update :). Particularly relevant changes for Qt are the use of the WebCore image decoders and direct usage
of libpng/libjpeg if available in the system.
Diffstat (limited to 'Tools/WebKitTestRunner')
9 files changed, 29 insertions, 17 deletions
diff --git a/Tools/WebKitTestRunner/Configurations/Base.xcconfig b/Tools/WebKitTestRunner/Configurations/Base.xcconfig index ab87999e9..4015b3e31 100644 --- a/Tools/WebKitTestRunner/Configurations/Base.xcconfig +++ b/Tools/WebKitTestRunner/Configurations/Base.xcconfig @@ -23,6 +23,7 @@ #include "CompilerVersion.xcconfig" +CLANG_WARN_CXX0X_EXTENSIONS = NO; HEADER_SEARCH_PATHS = $(BUILT_PRODUCTS_DIR)/usr/local/include $(WEBCORE_PRIVATE_HEADERS_DIR)/ForwardingHeaders ${SRCROOT}/../../Source/JavaScriptCore/icu $(NEXT_ROOT)/usr/local/include/WebCoreTestSupport; FRAMEWORK_SEARCH_PATHS = $(SYSTEM_LIBRARY_DIR)/Frameworks/Quartz.framework/Frameworks $(SYSTEM_LIBRARY_DIR)/Frameworks/ApplicationServices.framework/Frameworks $(SYSTEM_LIBRARY_DIR)/Frameworks/CoreServices.framework/Frameworks; GCC_PREPROCESSOR_DEFINITIONS = $(DEBUG_DEFINES) ENABLE_DASHBOARD_SUPPORT WEBKIT_VERSION_MIN_REQUIRED=WEBKIT_VERSION_LATEST; diff --git a/Tools/WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl b/Tools/WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl index 5e52ee8ba..819ea4600 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl +++ b/Tools/WebKitTestRunner/InjectedBundle/Bindings/LayoutTestController.idl @@ -54,6 +54,7 @@ module WTR { void setAllowUniversalAccessFromFileURLs(in boolean value); void setAllowFileAccessFromFileURLs(in boolean value); void setFrameFlatteningEnabled(in boolean value); + void setPluginsEnabled(in boolean value); void setGeolocationPermission(in boolean value); void setJavaScriptCanAccessClipboard(in boolean value); void setPrivateBrowsingEnabled(in boolean value); diff --git a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp index 05d4ea687..c9c3fec3d 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp +++ b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp @@ -230,7 +230,7 @@ void InjectedBundle::beginTesting(WKDictionaryRef settings) m_layoutTestController->setShouldDumpFrameLoadCallbacks(booleanForKey(settings, "DumpFrameLoadDelegates")); - page()->reset(); + page()->prepare(); WKBundleClearAllDatabases(m_bundle); WKBundleClearApplicationCache(m_bundle); @@ -260,7 +260,9 @@ void InjectedBundle::done() WKBundlePostMessage(m_bundle, doneMessageName.get(), doneMessageBody.get()); closeOtherPages(); - + + page()->resetAfterTest(); + m_state = Idle; } diff --git a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp index 57d2e1496..dc2ad3d39 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp +++ b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp @@ -330,7 +330,7 @@ void InjectedBundlePage::stopLoading() WKBundlePageStopLoading(m_page); } -void InjectedBundlePage::reset() +void InjectedBundlePage::prepare() { WKBundlePageClearMainFrameName(m_page); @@ -347,6 +347,17 @@ void InjectedBundlePage::reset() WKBundlePageSetTracksRepaints(m_page, false); } +void InjectedBundlePage::resetAfterTest() +{ + WKBundleFrameRef frame = WKBundlePageGetMainFrame(m_page); + JSGlobalContextRef context = WKBundleFrameGetJavaScriptContext(frame); +#if PLATFORM(QT) + DumpRenderTreeSupportQt::injectInternalsObject(context); +#else + WebCoreTestSupport::resetInternalsObject(context); +#endif +} + // Loader Client Callbacks // String output must be identical to -[WebFrame _drt_descriptionSuitableForTestResult]. diff --git a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.h b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.h index bce8ac038..4e1fce171 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.h +++ b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.h @@ -42,7 +42,8 @@ public: void stopLoading(); - void reset(); + void prepare(); + void resetAfterTest(); void dumpBackForwardList(); diff --git a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp index 250fa5c95..cca4de681 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp +++ b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp @@ -371,6 +371,11 @@ void LayoutTestController::setFrameFlatteningEnabled(bool enabled) WKBundleSetFrameFlatteningEnabled(InjectedBundle::shared().bundle(), InjectedBundle::shared().pageGroup(), enabled); } +void LayoutTestController::setPluginsEnabled(bool enabled) +{ + WKBundleSetPluginsEnabled(InjectedBundle::shared().bundle(), InjectedBundle::shared().pageGroup(), enabled); +} + void LayoutTestController::setGeolocationPermission(bool enabled) { WKBundleSetGeolocationPermission(InjectedBundle::shared().bundle(), InjectedBundle::shared().pageGroup(), enabled); @@ -478,13 +483,6 @@ void LayoutTestController::evaluateInWebInspector(long callID, JSStringRef scrip #endif // ENABLE(INSPECTOR) } -void LayoutTestController::setJavaScriptProfilingEnabled(bool enabled) -{ -#if ENABLE(INSPECTOR) - WKBundleInspectorSetJavaScriptProfilingEnabled(WKBundlePageGetInspector(InjectedBundle::shared().page()->page()), enabled); -#endif // ENABLE(INSPECTOR) -} - typedef WTF::HashMap<unsigned, WKRetainPtr<WKBundleScriptWorldRef> > WorldMap; static WorldMap& worldMap() { diff --git a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.h b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.h index 8ca09f61a..945a6609e 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.h +++ b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.h @@ -88,6 +88,7 @@ public: void setAllowUniversalAccessFromFileURLs(bool); void setAllowFileAccessFromFileURLs(bool); void setFrameFlatteningEnabled(bool); + void setPluginsEnabled(bool); void setGeolocationPermission(bool); void setJavaScriptCanAccessClipboard(bool); void setPrivateBrowsingEnabled(bool); @@ -174,7 +175,6 @@ public: void showWebInspector(); void closeWebInspector(); void evaluateInWebInspector(long callId, JSStringRef script); - void setJavaScriptProfilingEnabled(bool); void setPOSIXLocale(JSStringRef); diff --git a/Tools/WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp b/Tools/WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp index 72d04878a..5de8ae71a 100644 --- a/Tools/WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp +++ b/Tools/WebKitTestRunner/InjectedBundle/qt/LayoutTestControllerQt.cpp @@ -64,9 +64,7 @@ void LayoutTestController::platformInitialize() // which makes the use of QFontDatabase unnecessary. // See https://bugs.webkit.org/show_bug.cgi?id=53427 QWebSettings::clearMemoryCaches(); -#if !(QT_VERSION <= QT_VERSION_CHECK(4, 6, 2)) QFontDatabase::removeAllApplicationFonts(); -#endif activateFonts(); QObject::connect(&m_waitToDumpWatchdogTimer, SIGNAL(timeout()), WatchdogTimerHelper::instance(), SLOT(timerFired())); } diff --git a/Tools/WebKitTestRunner/TestController.cpp b/Tools/WebKitTestRunner/TestController.cpp index a7c3b6a05..ffdc2cc66 100644 --- a/Tools/WebKitTestRunner/TestController.cpp +++ b/Tools/WebKitTestRunner/TestController.cpp @@ -49,7 +49,7 @@ namespace WTR { static const double defaultLongTimeout = 30; -static const double defaultShortTimeout = 5; +static const double defaultShortTimeout = 15; static const double defaultNoTimeout = -1; static WKURLRef blankURL() @@ -498,9 +498,9 @@ bool TestController::runTest(const char* test) if (!resetStateToConsistentValues()) { #if PLATFORM(MAC) pid_t pid = WKPageGetProcessIdentifier(m_mainWebView->page()); - fprintf(stderr, "#CRASHED - WebProcess (pid %ld)\n", static_cast<long>(pid)); + fprintf(stderr, "#PROCESS UNRESPONSIVE - WebProcess (pid %ld)\n", static_cast<long>(pid)); #else - fputs("#CRASHED - WebProcess\n", stderr); + fputs("#PROCESS UNRESPONSIVE - WebProcess\n", stderr); #endif fflush(stderr); return false; |
