Commit 338e1fb6 authored by zherczeg@webkit.org's avatar zherczeg@webkit.org

2011-05-13 Zoltan Herczeg <zherczeg@webkit.org>

        Reviewed by Csaba Osztrogonác.

        Missing 2nd #EOF if WebProcess is killed.
        https://bugs.webkit.org/show_bug.cgi?id=60761

        If the WebProcess is killed, only one #EOF is yielded
        by WebKitTestRunner. However, run-webkit-test wait for
        a second #EOF, which signals the finishing of pixel dump.
        Since this never happens, run-webkit-test waits forever.

        * WebKitTestRunner/TestInvocation.cpp:
        (WTR::TestInvocation::dump):
        (WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
        * WebKitTestRunner/TestInvocation.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@86434 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 42ff713f
2011-05-13 Zoltan Herczeg <zherczeg@webkit.org>
Reviewed by Csaba Osztrogonác.
Missing 2nd #EOF if WebProcess is killed.
https://bugs.webkit.org/show_bug.cgi?id=60761
If the WebProcess is killed, only one #EOF is yielded
by WebKitTestRunner. However, run-webkit-test wait for
a second #EOF, which signals the finishing of pixel dump.
Since this never happens, run-webkit-test waits forever.
* WebKitTestRunner/TestInvocation.cpp:
(WTR::TestInvocation::dump):
(WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
* WebKitTestRunner/TestInvocation.h:
2011-05-13 Kristóf Kosztyó <Kosztyo.Kristof@stud.u-szeged.hu>
Reviewed by Csaba Osztrogonác.
......
......@@ -161,13 +161,15 @@ void TestInvocation::invoke()
WKInspectorClose(WKPageGetInspector(TestController::shared().mainWebView()->page()));
}
void TestInvocation::dump(const char* stringToDump)
void TestInvocation::dump(const char* stringToDump, bool singleEOF)
{
printf("Content-Type: text/plain\n");
printf("%s", stringToDump);
fputs("#EOF\n", stdout);
fputs("#EOF\n", stderr);
if (!singleEOF)
fputs("#EOF\n", stdout);
fflush(stdout);
fflush(stderr);
}
......@@ -207,7 +209,7 @@ void TestInvocation::didReceiveMessageFromInjectedBundle(WKStringRef messageName
ASSERT(!pixelResult || m_dumpPixels);
// Dump text.
dump(toSTD(textOutput).c_str());
dump(toSTD(textOutput).c_str(), true);
// Dump pixels (if necessary).
if (m_dumpPixels && pixelResult)
......
......@@ -45,7 +45,7 @@ public:
WKRetainPtr<WKTypeRef> didReceiveSynchronousMessageFromInjectedBundle(WKStringRef messageName, WKTypeRef messageBody);
private:
void dump(const char*);
void dump(const char*, bool singleEOF = false);
void dumpPixelsAndCompareWithExpected(WKImageRef);
WKRetainPtr<WKURLRef> m_url;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment