Commit 64d33e16 authored by ossy@webkit.org's avatar ossy@webkit.org

Unreviewed, rolling out r132819.

http://trac.webkit.org/changeset/132819
https://bugs.webkit.org/show_bug.cgi?id=100388

It made layout testing 40% slower and storage tests assert

Tools:

* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::DumpRenderTree::DumpRenderTree):
(WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting):
(WebCore::DumpRenderTree::dump):
* DumpRenderTree/qt/DumpRenderTreeQt.h:
(DumpRenderTree):
* DumpRenderTree/qt/TestRunnerQt.cpp:
(TestRunner::reset):
* DumpRenderTree/qt/TestRunnerQt.h:
(TestRunner):

LayoutTests:

* platform/qt/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@132873 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 0c654938
2012-10-29 Csaba Osztrogonác <ossy@webkit.org>
Unreviewed, rolling out r132819.
http://trac.webkit.org/changeset/132819
https://bugs.webkit.org/show_bug.cgi?id=100388
It made layout testing 40% slower and storage tests assert
* platform/qt/TestExpectations:
2012-10-25 Stephen Chenney <schenney@chromium.org>
feImage should not be allowed to self reference
......@@ -2450,6 +2450,11 @@ webkit.org/b/90007 http/tests/security/mixedContent/insecure-audio-video-in-main
# Skip tests in fast/text/shaping
webkit.org/b/90951 fast/text/shaping
# Flaky tests
webkit.org/b/91376 http/tests/security/sandboxed-iframe-modify-self.html [ Failure Pass ]
webkit.org/b/91379 http/tests/security/contentSecurityPolicy/policy-does-not-affect-child.html [ Failure Pass ]
webkit.org/b/91379 http/tests/security/contentSecurityPolicy/object-src-none-allowed.html [ Failure Pass ]
webkit.org/b/99756 fast/events/touch/touch-slider.html [ Failure ]
webkit.org/b/93247 [ Debug ] fast/lists/list-marker-remove-crash.html [ Crash ]
......
2012-10-29 Csaba Osztrogonác <ossy@webkit.org>
Unreviewed, rolling out r132819.
http://trac.webkit.org/changeset/132819
https://bugs.webkit.org/show_bug.cgi?id=100388
It made layout testing 40% slower and storage tests assert
* DumpRenderTree/qt/DumpRenderTreeQt.cpp:
(WebCore::DumpRenderTree::DumpRenderTree):
(WebCore::DumpRenderTree::resetToConsistentStateBeforeTesting):
(WebCore::DumpRenderTree::dump):
* DumpRenderTree/qt/DumpRenderTreeQt.h:
(DumpRenderTree):
* DumpRenderTree/qt/TestRunnerQt.cpp:
(TestRunner::reset):
* DumpRenderTree/qt/TestRunnerQt.h:
(TestRunner):
2012-10-29 Jochen Eisinger <jochen@chromium.org>
[chromium] TestRunner needs to compile ChromiumCurrentTime and ChromiumThreading in components build
......
......@@ -46,7 +46,6 @@
#include <QBuffer>
#include <QCryptographicHash>
#include <QDir>
#include <QElapsedTimer>
#include <QFile>
#include <QFileInfo>
#include <QFocusEvent>
......@@ -394,7 +393,6 @@ DumpRenderTree::DumpRenderTree()
, m_enableTextOutput(false)
, m_standAloneMode(false)
, m_graphicsBased(false)
, m_finishedResetting(false)
, m_persistentStoragePath(QString(getenv("DUMPRENDERTREE_TEMP")))
{
QByteArray viewMode = getenv("QT_DRT_WEBVIEW_MODE");
......@@ -510,37 +508,14 @@ void DumpRenderTree::dryRunPrint(QWebFrame* frame)
#endif
}
static void runUntil(bool& condition, double timeout)
{
int timeoutInMSecs = timeout * 1000;
QElapsedTimer timer;
timer.start();
while (!condition) {
if (timer.elapsed() > timeoutInMSecs)
return;
QCoreApplication::processEvents(QEventLoop::ExcludeUserInputEvents, timeoutInMSecs - timer.elapsed());
}
}
void DumpRenderTree::resetToConsistentStateBeforeTesting(const QUrl& url)
{
// Disable text-output first, because some tests can performed actions
// causing text dump out when stopped, and we do not want them dumping
// into the next test.
setTextOutputEnabled(false);
m_controller->resetDumping();
// Reset the page so that any current loads are stopped. We set to an
// empty page here instead of issuing a stop action, since setUrl also
// clears the current document.
// NOTE: that this has to be done before the testRunner is reset or we get timeouts for some tests.
m_finishedResetting = false;
connect(m_page, SIGNAL(loadFinished(bool)), this, SLOT(finishedResetting(bool)));
m_page->mainFrame()->setUrl(QUrl("about:blank"));
runUntil(m_finishedResetting, 5);
disconnect(m_page, SIGNAL(loadFinished(bool)), this, SLOT(finishedResetting(bool)));
// reset so that any current loads are stopped
// NOTE: that this has to be done before the testRunner is
// reset or we get timeouts for some tests.
m_page->blockSignals(true);
m_page->triggerAction(QWebPage::Stop);
m_page->blockSignals(false);
QList<QWebSecurityOrigin> knownOrigins = QWebSecurityOrigin::allOrigins();
for (int i = 0; i < knownOrigins.size(); ++i)
......@@ -598,11 +573,6 @@ void DumpRenderTree::resetToConsistentStateBeforeTesting(const QUrl& url)
DumpRenderTreeSupportQt::clearOpener(m_page->mainFrame());
}
void DumpRenderTree::finishedResetting(bool)
{
m_finishedResetting = true;
}
static bool isGlobalHistoryTest(const QUrl& url)
{
if (url.path().contains("globalhistory/"))
......@@ -926,8 +896,6 @@ static const char *methodNameStringForFailedTest(TestRunner *controller)
void DumpRenderTree::dump()
{
if (!isTextOutputEnabled())
return;
// Prevent any further frame load or resource load callbacks from appearing after we dump the result.
DumpRenderTreeSupportQt::dumpFrameLoader(false);
DumpRenderTreeSupportQt::dumpResourceLoadCallbacks(false);
......
......@@ -130,7 +130,6 @@ private Q_SLOTS:
void dryRunPrint(QWebFrame*);
void loadNextTestInStandAloneMode();
void geolocationPermissionSet();
void finishedResetting(bool);
private:
void setStandAloneMode(bool flag) { m_standAloneMode = flag; }
......@@ -159,7 +158,6 @@ private:
bool m_enableTextOutput;
bool m_standAloneMode;
bool m_graphicsBased;
bool m_finishedResetting;
QString m_persistentStoragePath;
QString m_redirectOutputFileName;
QString m_redirectErrorFileName;
......
......@@ -48,35 +48,21 @@ TestRunner::TestRunner(WebCore::DumpRenderTree* drt)
DumpRenderTreeSupportQt::dumpNotification(true);
}
void TestRunner::resetDumping()
{
m_dumpBackForwardList = false;
m_dumpChildrenAsText = false;
m_dumpChildFrameScrollPositions = false;
m_dumpTitleChanges = false;
m_dumpDatabaseCallbacks = false;
m_dumpApplicationCacheDelegateCallbacks = false;
m_dumpStatusCallbacks = false;
DumpRenderTreeSupportQt::dumpEditingCallbacks(false);
DumpRenderTreeSupportQt::dumpFrameLoader(false);
DumpRenderTreeSupportQt::dumpProgressFinishedCallback(false);
DumpRenderTreeSupportQt::dumpUserGestureInFrameLoader(false);
DumpRenderTreeSupportQt::dumpResourceLoadCallbacks(false);
DumpRenderTreeSupportQt::dumpResourceResponseMIMETypes(false);
DumpRenderTreeSupportQt::dumpWillCacheResponseCallbacks(false);
DumpRenderTreeSupportQt::dumpHistoryCallbacks(false);
DumpRenderTreeSupportQt::dumpVisitedLinksCallbacks(false);
DumpRenderTreeSupportQt::setCustomPolicyDelegate(false, false);
}
void TestRunner::reset()
{
m_hasDumped = false;
m_loadFinished = false;
m_textDump = false;
m_dumpBackForwardList = false;
m_dumpChildrenAsText = false;
m_dumpChildFrameScrollPositions = false;
m_canOpenWindows = false;
m_waitForDone = false;
m_disallowIncreaseForApplicationCacheQuota = false;
m_dumpTitleChanges = false;
m_dumpDatabaseCallbacks = false;
m_dumpApplicationCacheDelegateCallbacks = false;
m_dumpStatusCallbacks = false;
m_timeoutTimer.stop();
m_topLoadingFrame = 0;
m_waitForPolicy = false;
......@@ -90,11 +76,21 @@ void TestRunner::reset()
m_isPrinting = false;
m_geolocationPermission = false;
DumpRenderTreeSupportQt::dumpEditingCallbacks(false);
DumpRenderTreeSupportQt::dumpFrameLoader(false);
DumpRenderTreeSupportQt::dumpProgressFinishedCallback(false);
DumpRenderTreeSupportQt::dumpUserGestureInFrameLoader(false);
DumpRenderTreeSupportQt::dumpResourceLoadCallbacks(false);
DumpRenderTreeSupportQt::dumpResourceResponseMIMETypes(false);
DumpRenderTreeSupportQt::dumpWillCacheResponseCallbacks(false);
DumpRenderTreeSupportQt::setDeferMainResourceDataLoad(true);
DumpRenderTreeSupportQt::setWillSendRequestReturnsNullOnRedirect(false);
DumpRenderTreeSupportQt::setWillSendRequestReturnsNull(false);
DumpRenderTreeSupportQt::setWillSendRequestClearHeaders(QStringList());
DumpRenderTreeSupportQt::clearScriptWorlds();
DumpRenderTreeSupportQt::setCustomPolicyDelegate(false, false);
DumpRenderTreeSupportQt::dumpHistoryCallbacks(false);
DumpRenderTreeSupportQt::dumpVisitedLinksCallbacks(false);
DumpRenderTreeSupportQt::resetGeolocationMock(m_drt->webPage());
setIconDatabaseEnabled(false);
clearAllDatabases();
......
......@@ -78,7 +78,6 @@ public:
bool isPrinting() { return m_isPrinting; }
void reset();
void resetDumping();
static const unsigned int maxViewWidth;
static const unsigned int maxViewHeight;
......
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