summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/extras/qtext2dentity/tst_qtext2dentity.cpp2
-rw-r--r--tests/auto/quick3d/3dinput/3dinput.qml3
-rw-r--r--tests/auto/render/opengl/filtercompatibletechniquejob/tst_filtercompatibletechniquejob.cpp2
-rw-r--r--tests/auto/render/opengl/graphicshelpergl2/tst_graphicshelpergl2.cpp5
-rw-r--r--tests/auto/render/opengl/graphicshelpergl3_2/tst_graphicshelpergl3_2.cpp5
-rw-r--r--tests/auto/render/opengl/graphicshelpergl3_3/graphicshelpergl3_3.pro2
-rw-r--r--tests/auto/render/opengl/graphicshelpergl3_3/tst_graphicshelpergl3_3.cpp5
-rw-r--r--tests/auto/render/opengl/graphicshelpergl4/tst_graphicshelpergl4.cpp5
-rw-r--r--tests/auto/render/render.pro4
-rw-r--r--tests/auto/render/shadergraph/qshadernodesloader/tst_qshadernodesloader.cpp11
10 files changed, 29 insertions, 15 deletions
diff --git a/tests/auto/extras/qtext2dentity/tst_qtext2dentity.cpp b/tests/auto/extras/qtext2dentity/tst_qtext2dentity.cpp
index 6fcc2e637..e2917789e 100644
--- a/tests/auto/extras/qtext2dentity/tst_qtext2dentity.cpp
+++ b/tests/auto/extras/qtext2dentity/tst_qtext2dentity.cpp
@@ -77,7 +77,7 @@ private slots:
void tst_qtext2dentity::checkChangeArbiter()
{
-#if !defined(QT_OPENGL_ES_2_ANGLE)
+#if !QT_CONFIG(angle)
// GIVEN
Qt3DExtras::Quick::Qt3DQuickWindow view;
view.setSource(QUrl("qrc:/qtext2dentity.qml"));
diff --git a/tests/auto/quick3d/3dinput/3dinput.qml b/tests/auto/quick3d/3dinput/3dinput.qml
index 9ae53f66a..b95a8d460 100644
--- a/tests/auto/quick3d/3dinput/3dinput.qml
+++ b/tests/auto/quick3d/3dinput/3dinput.qml
@@ -47,6 +47,7 @@ Item {
QQ3Input20.AxisSetting {} //Qt3DInput::QAxisSetting
QQ3Input20.AnalogAxisInput {} //Qt3DInput::QAnalogAxisInput
QQ3Input20.ButtonAxisInput {} //Qt3DInput::QButtonAxisInput
- QQ3Input20.GamepadInput {} //Qt3DInput::QGamepadInput
+ // Disabled for Qt 6
+ // QQ3Input20.GamepadInput {} //Qt3DInput::QGamepadInput
}
diff --git a/tests/auto/render/opengl/filtercompatibletechniquejob/tst_filtercompatibletechniquejob.cpp b/tests/auto/render/opengl/filtercompatibletechniquejob/tst_filtercompatibletechniquejob.cpp
index e5c34f804..7d897a358 100644
--- a/tests/auto/render/opengl/filtercompatibletechniquejob/tst_filtercompatibletechniquejob.cpp
+++ b/tests/auto/render/opengl/filtercompatibletechniquejob/tst_filtercompatibletechniquejob.cpp
@@ -179,7 +179,7 @@ private Q_SLOTS:
void initTestCase()
{
QSurfaceFormat format;
-#ifdef QT_OPENGL_ES_2
+#if QT_CONFIG(opengles2)
format.setRenderableType(QSurfaceFormat::OpenGLES);
#else
if (QOpenGLContext::openGLModuleType() == QOpenGLContext::LibGL) {
diff --git a/tests/auto/render/opengl/graphicshelpergl2/tst_graphicshelpergl2.cpp b/tests/auto/render/opengl/graphicshelpergl2/tst_graphicshelpergl2.cpp
index 5a1d22283..f733697f7 100644
--- a/tests/auto/render/opengl/graphicshelpergl2/tst_graphicshelpergl2.cpp
+++ b/tests/auto/render/opengl/graphicshelpergl2/tst_graphicshelpergl2.cpp
@@ -33,13 +33,14 @@
#include <Qt3DRender/private/attachmentpack_p.h>
#include <QtOpenGLExtensions/QOpenGLExtensions>
#include <QOpenGLContext>
+#include <QOpenGLVersionFunctionsFactory>
#include <QOpenGLBuffer>
#include <QOpenGLFunctions_2_0>
#include <QOpenGLShaderProgram>
#include <QOpenGLVertexArrayObject>
#include <QSurfaceFormat>
-#ifndef QT_OPENGL_ES_2
+#if !QT_CONFIG(opengles2)
#define TEST_SHOULD_BE_PERFORMED 1
@@ -153,7 +154,7 @@ private Q_SLOTS:
return;
}
- if ((m_func = m_glContext.versionFunctions<QOpenGLFunctions_2_0>()) != nullptr) {
+ if ((m_func = QOpenGLVersionFunctionsFactory::get<QOpenGLFunctions_2_0>()) != nullptr) {
if (m_glContext.hasExtension(QByteArrayLiteral("GL_ARB_framebuffer_object"))) {
m_fboFuncs = new QOpenGLExtension_ARB_framebuffer_object();
m_fboFuncs->initializeOpenGLFunctions();
diff --git a/tests/auto/render/opengl/graphicshelpergl3_2/tst_graphicshelpergl3_2.cpp b/tests/auto/render/opengl/graphicshelpergl3_2/tst_graphicshelpergl3_2.cpp
index 08c30dc15..e784e5b9a 100644
--- a/tests/auto/render/opengl/graphicshelpergl3_2/tst_graphicshelpergl3_2.cpp
+++ b/tests/auto/render/opengl/graphicshelpergl3_2/tst_graphicshelpergl3_2.cpp
@@ -32,12 +32,13 @@
#include <graphicshelpergl3_2_p.h>
#include <Qt3DRender/private/attachmentpack_p.h>
#include <QOpenGLBuffer>
+#include <QOpenGLVersionFunctionsFactory>
#include <QOpenGLFunctions_3_2_Core>
#include <QOpenGLShaderProgram>
#include <QOpenGLVertexArrayObject>
#include <QSurfaceFormat>
-#if !defined(QT_OPENGL_ES_2) && defined(QT_OPENGL_3_2)
+#if !QT_CONFIG(opengles2) && defined(QT_OPENGL_3_2)
#define TEST_SHOULD_BE_PERFORMED 1
@@ -207,7 +208,7 @@ private Q_SLOTS:
return;
}
- if ((m_func = m_glContext.versionFunctions<QOpenGLFunctions_3_2_Core>()) != nullptr) {
+ if ((m_func = QOpenGLVersionFunctionsFactory::get<QOpenGLFunctions_3_2_Core>()) != nullptr) {
m_glHelper.initializeHelper(&m_glContext, m_func);
m_initializationSuccessful = true;
}
diff --git a/tests/auto/render/opengl/graphicshelpergl3_3/graphicshelpergl3_3.pro b/tests/auto/render/opengl/graphicshelpergl3_3/graphicshelpergl3_3.pro
index 5ef0b6806..ae8e06eba 100644
--- a/tests/auto/render/opengl/graphicshelpergl3_3/graphicshelpergl3_3.pro
+++ b/tests/auto/render/opengl/graphicshelpergl3_3/graphicshelpergl3_3.pro
@@ -2,7 +2,7 @@ TEMPLATE = app
TARGET = tst_graphicshelpergl3_3
-QT += 3dcore 3dcore-private 3drender 3drender-private testlib
+QT += 3dcore 3dcore-private 3drender 3drender-private testlib opengl
CONFIG += testcase
diff --git a/tests/auto/render/opengl/graphicshelpergl3_3/tst_graphicshelpergl3_3.cpp b/tests/auto/render/opengl/graphicshelpergl3_3/tst_graphicshelpergl3_3.cpp
index b463e6236..7e2ca4aa0 100644
--- a/tests/auto/render/opengl/graphicshelpergl3_3/tst_graphicshelpergl3_3.cpp
+++ b/tests/auto/render/opengl/graphicshelpergl3_3/tst_graphicshelpergl3_3.cpp
@@ -32,11 +32,12 @@
#include <Qt3DRender/private/attachmentpack_p.h>
#include <graphicshelpergl3_3_p.h>
#include <QOpenGLBuffer>
+#include <QOpenGLVersionFunctionsFactory>
#include <QOpenGLFunctions_3_3_Core>
#include <QOpenGLShaderProgram>
#include <QOpenGLVertexArrayObject>
-#if !defined(QT_OPENGL_ES_2) && defined(QT_OPENGL_3_2)
+#if !QT_CONFIG(opengles2) && defined(QT_OPENGL_3_2)
#define TEST_SHOULD_BE_PERFORMED 1
@@ -207,7 +208,7 @@ private Q_SLOTS:
return;
}
- if ((m_func = m_glContext.versionFunctions<QOpenGLFunctions_3_3_Core>()) != nullptr) {
+ if ((m_func = QOpenGLVersionFunctionsFactory::get<QOpenGLFunctions_3_3_Core>()) != nullptr) {
m_glHelper.initializeHelper(&m_glContext, m_func);
m_initializationSuccessful = true;
}
diff --git a/tests/auto/render/opengl/graphicshelpergl4/tst_graphicshelpergl4.cpp b/tests/auto/render/opengl/graphicshelpergl4/tst_graphicshelpergl4.cpp
index 8f86f38ce..92a4a4af0 100644
--- a/tests/auto/render/opengl/graphicshelpergl4/tst_graphicshelpergl4.cpp
+++ b/tests/auto/render/opengl/graphicshelpergl4/tst_graphicshelpergl4.cpp
@@ -36,8 +36,9 @@
#include <QOpenGLShaderProgram>
#include <QOpenGLVertexArrayObject>
#include <QSurfaceFormat>
+#include <QtOpenGL/QOpenGLVersionFunctionsFactory>
-#if !defined(QT_OPENGL_ES_2) && defined(QT_OPENGL_4_3)
+#if !QT_CONFIG(opengles2) && defined(QT_OPENGL_4_3)
#define TEST_SHOULD_BE_PERFORMED 1
@@ -255,7 +256,7 @@ private Q_SLOTS:
return;
}
- if ((m_func = m_glContext.versionFunctions<QOpenGLFunctions_4_3_Core>()) != nullptr) {
+ if ((m_func = QOpenGLVersionFunctionsFactory::get<QOpenGLFunctions_4_3_Core>()) != nullptr) {
m_glHelper.initializeHelper(&m_glContext, m_func);
m_initializationSuccessful = true;
}
diff --git a/tests/auto/render/render.pro b/tests/auto/render/render.pro
index e772e3ddd..4582b7644 100644
--- a/tests/auto/render/render.pro
+++ b/tests/auto/render/render.pro
@@ -143,9 +143,7 @@ qtConfig(qt3d-opengl-renderer):qtConfig(private_tests) {
qmaterial \
geometryloaders \
picking \
- pickboundingvolumejob \
- gltfplugins \
- updateshaderdatatransformjob
+ gltfplugins
}
qtConfig(qt3d-input) {
diff --git a/tests/auto/render/shadergraph/qshadernodesloader/tst_qshadernodesloader.cpp b/tests/auto/render/shadergraph/qshadernodesloader/tst_qshadernodesloader.cpp
index 27cf7f425..efce243bd 100644
--- a/tests/auto/render/shadergraph/qshadernodesloader/tst_qshadernodesloader.cpp
+++ b/tests/auto/render/shadergraph/qshadernodesloader/tst_qshadernodesloader.cpp
@@ -32,6 +32,7 @@
#include <QtCore/qbuffer.h>
#include <Qt3DRender/private/qshadernodesloader_p.h>
+#include <Qt3DRender/private/qshadergraphloader_p.h>
#include <Qt3DRender/private/qshaderlanguage_p.h>
using namespace Qt3DRender;
@@ -86,11 +87,21 @@ class tst_QShaderNodesLoader : public QObject
{
Q_OBJECT
private slots:
+ void initTestCase();
void shouldManipulateLoaderMembers();
void shouldLoadFromJsonStream_data();
void shouldLoadFromJsonStream();
};
+void tst_QShaderNodesLoader::initTestCase()
+{
+ // Make sure we register the meta types. This is done by the
+ // QShaderGraphLoader ctor usually but in this test, no QShaderGraphLoader
+ // is used so we need to to it ourselves
+ QShaderGraphLoader l;
+ Q_UNUSED(l);
+}
+
void tst_QShaderNodesLoader::shouldManipulateLoaderMembers()
{
// GIVEN