[SCM] WebKit Debian packaging branch, debian/experimental, updated. debian/1.3.8-1-1049-g2e11a8e

mjs at apple.com mjs at apple.com
Fri Jan 21 15:09:44 UTC 2011


The following commit has been merged in the debian/experimental branch:
commit 9dadbf4a02fe14d221664df2bcbcd05fc78904cd
Author: mjs at apple.com <mjs at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sat Jan 8 00:21:52 2011 +0000

    2011-01-07  Maciej Stachowiak  <mjs at apple.com>
    
            Reviewed by Sam Weinig.
    
            Make WebKitTestRunner rest between loads more robust to avoid test crashes
            https://bugs.webkit.org/show_bug.cgi?id=52086
    
            * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
            (WTR::InjectedBundle::didReceiveMessage):
            * WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
            (WTR::LayoutTestController::notifyDone):
            * WebKitTestRunner/TestController.cpp:
            (WTR::TestController::resetStateToConsistentValues):
            (WTR::TestController::run):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@75291 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/Tools/ChangeLog b/Tools/ChangeLog
index dcdfc5f..70f7a4f 100644
--- a/Tools/ChangeLog
+++ b/Tools/ChangeLog
@@ -1,3 +1,18 @@
+2011-01-07  Maciej Stachowiak  <mjs at apple.com>
+
+        Reviewed by Sam Weinig.
+
+        Make WebKitTestRunner rest between loads more robust to avoid test crashes
+        https://bugs.webkit.org/show_bug.cgi?id=52086
+
+        * WebKitTestRunner/InjectedBundle/InjectedBundle.cpp:
+        (WTR::InjectedBundle::didReceiveMessage):
+        * WebKitTestRunner/InjectedBundle/LayoutTestController.cpp:
+        (WTR::LayoutTestController::notifyDone):
+        * WebKitTestRunner/TestController.cpp:
+        (WTR::TestController::resetStateToConsistentValues):
+        (WTR::TestController::run):
+
 2011-01-07  James Robinson  <jamesr at chromium.org>
 
         Revert "Implement mozilla's animationTime property"
diff --git a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp
index 49d9db6..f68d3c4 100644
--- a/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp
+++ b/Tools/WebKitTestRunner/InjectedBundle/InjectedBundle.cpp
@@ -128,6 +128,9 @@ void InjectedBundle::didReceiveMessage(WKStringRef messageName, WKTypeRef messag
 
         beginTesting();
         return;
+    } else if (WKStringIsEqualToUTF8CString(messageName, "Reset")) {
+        m_state = Idle;
+        return;
     }
 
     WKRetainPtr<WKStringRef> errorMessageName(AdoptWK, WKStringCreateWithUTF8CString("Error"));
diff --git a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp
index 60e3130..aa3dbf4 100644
--- a/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp
+++ b/Tools/WebKitTestRunner/InjectedBundle/LayoutTestController.cpp
@@ -129,6 +129,9 @@ void LayoutTestController::waitToDumpWatchdogTimerFired()
 
 void LayoutTestController::notifyDone()
 {
+    if (!InjectedBundle::shared().isTestRunning())
+        return;
+
     if (m_waitToDump && !InjectedBundle::shared().page()->isLoading())
         InjectedBundle::shared().page()->dump();
     m_waitToDump = false;
diff --git a/Tools/WebKitTestRunner/TestController.cpp b/Tools/WebKitTestRunner/TestController.cpp
index 77213a2..3ea46ee 100644
--- a/Tools/WebKitTestRunner/TestController.cpp
+++ b/Tools/WebKitTestRunner/TestController.cpp
@@ -280,6 +280,9 @@ bool TestController::resetStateToConsistentValues()
 {
     m_state = Resetting;
 
+    WKRetainPtr<WKStringRef> messageName(AdoptWK, WKStringCreateWithUTF8CString("Reset"));
+    WKContextPostMessageToInjectedBundle(TestController::shared().context(), messageName.get(), 0);
+
     // FIXME: This function should also ensure that there is only one page open.
 
     // Reset preferences
@@ -353,6 +356,7 @@ void TestController::run()
                 break;
         }
     }
+
 }
 
 void TestController::runUntil(bool& done, TimeoutDuration timeoutDuration)

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list