From ac8ebc6c3a56064f88f5506e5e3783ab7bee2456 Mon Sep 17 00:00:00 2001 From: Konstantin Tokarev Date: Tue, 22 Sep 2020 14:30:04 +0300 Subject: Enable QML tests Change-Id: I10968ff39311aac6af328e5f13e316dbfc3c7a1e Reviewed-by: Konstantin Tokarev --- Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp | 4 ++++ tests/webkitqml/qmltests/DesktopBehavior.pro | 18 ------------------ .../qmltests/DesktopBehavior/DesktopBehavior.pro | 18 ++++++++++++++++++ tests/webkitqml/qmltests/WebView.pro | 19 ------------------- tests/webkitqml/qmltests/WebView/BLACKLIST | 4 ++++ tests/webkitqml/qmltests/WebView/WebView.pro | 19 +++++++++++++++++++ tests/webkitqml/qmltests/qmltests.pro | 2 +- tests/webkitqml/tests.pri | 8 ++++---- tests/webkitqml/webkitqml.pro | 2 +- 9 files changed, 51 insertions(+), 43 deletions(-) delete mode 100644 tests/webkitqml/qmltests/DesktopBehavior.pro create mode 100644 tests/webkitqml/qmltests/DesktopBehavior/DesktopBehavior.pro delete mode 100644 tests/webkitqml/qmltests/WebView.pro create mode 100644 tests/webkitqml/qmltests/WebView/BLACKLIST create mode 100644 tests/webkitqml/qmltests/WebView/WebView.pro diff --git a/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp b/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp index 3902003f9..7280c56d9 100644 --- a/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp +++ b/Source/WebKit2/Platform/IPC/unix/ConnectionUnix.cpp @@ -368,6 +368,10 @@ static ssize_t readBytesFromSocket(int socketDescriptor, Vector& buffer void Connection::readyReadHandler() { #if PLATFORM(QT) + if (!m_socketNotifier) { + WTFLogAlways("Error receiving IPC message on socket %d in process %d: m_socketNotifier is null", m_socketDescriptor, getpid()); + return; + } SocketNotifierResourceGuard socketNotifierEnabler(m_socketNotifier); #endif diff --git a/tests/webkitqml/qmltests/DesktopBehavior.pro b/tests/webkitqml/qmltests/DesktopBehavior.pro deleted file mode 100644 index e8ac901f1..000000000 --- a/tests/webkitqml/qmltests/DesktopBehavior.pro +++ /dev/null @@ -1,18 +0,0 @@ -include(../tests.pri) -SOURCES += tst_qmltests.cpp -TARGET = tst_qmltests_DesktopBehavior -OBJECTS_DIR = .obj_DesktopBehavior - -QT += webkit-private -CONFIG += testcase - -QT += qmltest - -DEFINES += DISABLE_FLICKABLE_VIEWPORT=1 -# Test the QML files under DesktopBehavior in the source repository. -DEFINES += QUICK_TEST_SOURCE_DIR=\"\\\"$$PWD$${QMAKE_DIR_SEP}DesktopBehavior\\\"\" -DEFINES += IMPORT_DIR=\"\\\"$${ROOT_BUILD_DIR}$${QMAKE_DIR_SEP}imports\\\"\" - -OTHER_FILES += \ - DesktopBehavior/* \ - common/* diff --git a/tests/webkitqml/qmltests/DesktopBehavior/DesktopBehavior.pro b/tests/webkitqml/qmltests/DesktopBehavior/DesktopBehavior.pro new file mode 100644 index 000000000..4846d242d --- /dev/null +++ b/tests/webkitqml/qmltests/DesktopBehavior/DesktopBehavior.pro @@ -0,0 +1,18 @@ +include(../../tests.pri) +SOURCES += ../tst_qmltests.cpp +TARGET = tst_qmltests_DesktopBehavior +OBJECTS_DIR = .obj_DesktopBehavior + +QT += webkit-private +CONFIG += testcase + +QT += qmltest + +DEFINES += DISABLE_FLICKABLE_VIEWPORT=1 +# Test the QML files under DesktopBehavior in the source repository. +DEFINES += QUICK_TEST_SOURCE_DIR=\"\\\"$$PWD\\\"\" +DEFINES += IMPORT_DIR=\"\\\"$${ROOT_BUILD_DIR}$${QMAKE_DIR_SEP}imports\\\"\" + +OTHER_FILES += \ + *.qml \ + ../common/* diff --git a/tests/webkitqml/qmltests/WebView.pro b/tests/webkitqml/qmltests/WebView.pro deleted file mode 100644 index 6c67da96e..000000000 --- a/tests/webkitqml/qmltests/WebView.pro +++ /dev/null @@ -1,19 +0,0 @@ -include(../tests.pri) -SOURCES += tst_qmltests.cpp -TARGET = tst_qmltests_WebView -OBJECTS_DIR = .obj_WebView - -QT += webkit-private -CONFIG += testcase - -QT += qmltest - -# Test the QML files under WebView in the source repository. -DEFINES += QUICK_TEST_SOURCE_DIR=\"\\\"$$PWD$${QMAKE_DIR_SEP}WebView\\\"\" -DEFINES += IMPORT_DIR=\"\\\"$${ROOT_BUILD_DIR}$${QMAKE_DIR_SEP}imports\\\"\" - -OTHER_FILES += \ - WebView/* \ - common/* - -RESOURCES = resources.qrc diff --git a/tests/webkitqml/qmltests/WebView/BLACKLIST b/tests/webkitqml/qmltests/WebView/BLACKLIST new file mode 100644 index 000000000..843ee3e7e --- /dev/null +++ b/tests/webkitqml/qmltests/WebView/BLACKLIST @@ -0,0 +1,4 @@ +[WebViewLoadFavIcon::test_favIconLoad] +ci * +[WebViewLoadFavIcon::test_favIconLoadEncodedUrl] +ci * diff --git a/tests/webkitqml/qmltests/WebView/WebView.pro b/tests/webkitqml/qmltests/WebView/WebView.pro new file mode 100644 index 000000000..f468646b3 --- /dev/null +++ b/tests/webkitqml/qmltests/WebView/WebView.pro @@ -0,0 +1,19 @@ +include(../../tests.pri) +SOURCES += ../tst_qmltests.cpp +TARGET = tst_qmltests_WebView +OBJECTS_DIR = .obj_WebView + +QT += webkit-private +CONFIG += testcase + +QT += qmltest + +# Test the QML files under WebView in the source repository. +DEFINES += QUICK_TEST_SOURCE_DIR=\"\\\"$$PWD\\\"\" +DEFINES += IMPORT_DIR=\"\\\"$${ROOT_BUILD_DIR}$${QMAKE_DIR_SEP}imports\\\"\" + +OTHER_FILES += \ + *.qml \ + ../common/* + +RESOURCES = ../resources.qrc diff --git a/tests/webkitqml/qmltests/qmltests.pro b/tests/webkitqml/qmltests/qmltests.pro index 8ddc4484e..7f2847894 100644 --- a/tests/webkitqml/qmltests/qmltests.pro +++ b/tests/webkitqml/qmltests/qmltests.pro @@ -1,3 +1,3 @@ TEMPLATE = subdirs -SUBDIRS += DesktopBehavior.pro WebView.pro +SUBDIRS += DesktopBehavior WebView diff --git a/tests/webkitqml/tests.pri b/tests/webkitqml/tests.pri index 0fb41b959..f5ec08535 100644 --- a/tests/webkitqml/tests.pri +++ b/tests/webkitqml/tests.pri @@ -4,16 +4,16 @@ VPATH += $$_PRO_FILE_PWD_ TARGET = tst_$$TARGET INCLUDEPATH += $$PWD -SOURCES += ../util.cpp +SOURCES += $$PWD/util.cpp QT += testlib webkit qtHaveModule(quick) { QT += qml quick quick-private - HEADERS += ../bytearraytestdata.h \ - ../util.h + HEADERS += $$PWD/bytearraytestdata.h \ + $$PWD/util.h - SOURCES += ../bytearraytestdata.cpp + SOURCES += $$PWD/bytearraytestdata.cpp } WEBKIT += wtf # For platform macros diff --git a/tests/webkitqml/webkitqml.pro b/tests/webkitqml/webkitqml.pro index 2af7ec801..248be9fb4 100644 --- a/tests/webkitqml/webkitqml.pro +++ b/tests/webkitqml/webkitqml.pro @@ -1,2 +1,2 @@ TEMPLATE = subdirs -# SUBDIRS += qmltests +SUBDIRS += qmltests -- cgit v1.2.1