Fix QtGui dependencies in tests/benchmarks

Before this change, -no-gui builds failed already while running qmake.

Change-Id: I3e300a16669371098589822806c5cf8aa9b801c7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
This commit is contained in:
Kai Pastor 2016-03-25 22:26:36 +01:00
parent fc65b9a7cb
commit f805d7075a
5 changed files with 11 additions and 5 deletions

View File

@ -1,4 +1,4 @@
QT += testlib
QT = core testlib
TEMPLATE = app
TARGET = tst_bench_qcoreapplication

View File

@ -1,5 +1,6 @@
TARGET = tst_bench_qvariant
QT += testlib
!qtHaveModule(gui): QT -= gui
CONFIG += release
#CONFIG += debug

View File

@ -32,7 +32,9 @@
****************************************************************************/
#include <QtCore>
#include <QtGui/QPixmap>
#ifdef QT_GUI_LIB
# include <QtGui/QPixmap>
#endif
#include <qtest.h>
#define ITERATION_COUNT 1e5
@ -47,7 +49,9 @@ private slots:
void floatVariantCreation();
void rectVariantCreation();
void stringVariantCreation();
#ifdef QT_GUI_LIB
void pixmapVariantCreation();
#endif
void stringListVariantCreation();
void bigClassVariantCreation();
void smallClassVariantCreation();
@ -158,10 +162,12 @@ void tst_qvariant::stringVariantCreation()
variantCreation<QString>(QString());
}
#ifdef QT_GUI_LIB
void tst_qvariant::pixmapVariantCreation()
{
variantCreation<QPixmap>(QPixmap());
}
#endif
void tst_qvariant::stringListVariantCreation()
{

View File

@ -1,8 +1,7 @@
TEMPLATE = app
TARGET = tst_bench_qnetworkdiskcache
QT += gui # for QDesktopServices
QT += network testlib
QT = core network testlib
CONFIG += release

View File

@ -1,3 +1,3 @@
TARGET = tst_bench_qnetworkreply_from_cache
QT += network testlib
QT = core network testlib
SOURCES += tst_qnetworkreply_from_cache.cpp