Bug 29844

Summary: [Qt] QWebPage's autotest dependency
Product: WebKit Reporter: Jędrzej Nowacki <jedrzej.nowacki>
Component: Tools / TestsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: hausmann, laszlo.gombos
Priority: P2 Keywords: Qt
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Linux   
Bug Depends on:    
Bug Blocks: 29867    
Attachments:
Description Flags
Fix for autotest hausmann: review+

Description Jędrzej Nowacki 2009-09-29 04:07:40 PDT
There is dependency between QWebPage autotest ::databese() and ::testEnablePersistentStorage(). It looks like database connection stay opened after test.

~/dev/webkit/WebKitBuild/Debug/WebKit/qt/tests/qwebpage$ ./tst_qwebpage database
********* Start testing of tst_QWebPage *********
Config: Using QTest library 4.6.0, Qt 4.6.0
PASS   : tst_QWebPage::initTestCase()
PASS   : tst_QWebPage::database()
PASS   : tst_QWebPage::cleanupTestCase()
Totals: 3 passed, 0 failed, 0 skipped
********* Finished testing of tst_QWebPage *********
LEAK: 224 Structure
LEAK: 5 WebCoreNode
~/dev/webkit/WebKitBuild/Debug/WebKit/qt/tests/qwebpage$ ./tst_qwebpage testEnablePersistentStorage
********* Start testing of tst_QWebPage *********
Config: Using QTest library 4.6.0, Qt 4.6.0
PASS   : tst_QWebPage::initTestCase()
PASS   : tst_QWebPage::testEnablePersistentStorage()
PASS   : tst_QWebPage::cleanupTestCase()
Totals: 3 passed, 0 failed, 0 skipped
********* Finished testing of tst_QWebPage *********
~/dev/webkit/WebKitBuild/Debug/WebKit/qt/tests/qwebpage$ ./tst_qwebpage database testEnablePersistentStorage
********* Start testing of tst_QWebPage *********
Config: Using QTest library 4.6.0, Qt 4.6.0
PASS   : tst_QWebPage::initTestCase()
PASS   : tst_QWebPage::database()
ASSERTION FAILED: !m_database.isOpen()
(../../../WebCore/storage/DatabaseTracker.cpp:78 void WebCore::DatabaseTracker::setDatabaseDirectoryPath(const WebCore::String&))
QFATAL : tst_QWebPage::testEnablePersistentStorage() Received signal 11
FAIL!  : tst_QWebPage::testEnablePersistentStorage() Received a fatal error.
   Loc: [Unknown file(0)]
Totals: 2 passed, 1 failed, 0 skipped
********* Finished testing of tst_QWebPage *********
Aborted
Comment 1 Tor Arne Vestbø 2009-09-29 05:12:11 PDT
Please follow the QtWebKit bug reporting guidlines:

http://trac.webkit.org/wiki/QtWebKitContrib#ReportingBugs

In particular:

    - All bugs related to the Qt port of WebKit should have the keyword 'Qt'
    - The 'WebKit Qt' component should only be used for the QtWebKit API layer
Comment 2 Jędrzej Nowacki 2009-09-29 05:17:04 PDT
Created attachment 40296 [details]
Fix for autotest

In patch I assume that some databases might be shared between different instances of QWebPage. If it's not the case, ~QWebPage should implicitly remove all opened databases.
Comment 3 Simon Hausmann 2009-09-29 07:07:58 PDT
Committed r48872: <http://trac.webkit.org/changeset/48872>