From 502b64e06a27c8170c3dc5532ec139b4030268f1 Mon Sep 17 00:00:00 2001 From: Kurt Korbatits Date: Tue, 17 Jan 2012 09:41:17 +1000 Subject: Changed qpainter unittest to work from installation directory - Changed to use QFINDTESTDATA and TESTDATA Change-Id: If75ae2b8e39f6388f4e84ed4aa2681b5a5917e81 Reviewed-by: Kurt Korbatits Reviewed-by: Rohan McGovern Reviewed-by: Jason McDonald --- tests/auto/gui/painting/qpainter/qpainter.pro | 12 +++--------- tests/auto/gui/painting/qpainter/tst_qpainter.cpp | 2 +- 2 files changed, 4 insertions(+), 10 deletions(-) (limited to 'tests') diff --git a/tests/auto/gui/painting/qpainter/qpainter.pro b/tests/auto/gui/painting/qpainter/qpainter.pro index 716d70c7f5..0209043d20 100644 --- a/tests/auto/gui/painting/qpainter/qpainter.pro +++ b/tests/auto/gui/painting/qpainter/qpainter.pro @@ -4,13 +4,7 @@ TARGET = tst_qpainter QT += widgets widgets-private printsupport testlib SOURCES += tst_qpainter.cpp -wince* { - addFiles.files = drawEllipse drawLine_rop_bitmap drawPixmap_rop drawPixmap_rop_bitmap task217400.png - addFiles.path = . - DEPLOYMENT += addFiles - DEFINES += SRCDIR=\\\".\\\" -} else { - DEFINES += SRCDIR=\\\"$$PWD\\\" -} - mac*:CONFIG+=insignificant_test + +TESTDATA += drawEllipse/* drawLine_rop_bitmap/* drawPixmap_rop/* drawPixmap_rop_bitmap/* \ + task217400.png diff --git a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp index d6511d4475..4abaa34df8 100644 --- a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp +++ b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp @@ -3108,7 +3108,7 @@ void tst_QPainter::drawImage_task217400() { QFETCH(QImage::Format, format); - const QImage src = QImage(QString(SRCDIR) + "/task217400.png") + const QImage src = QImage(QFINDTESTDATA("task217400.png")) .convertToFormat(format); QVERIFY(!src.isNull()); -- cgit v1.2.3