From 0923b0b56e631031461cc7bde56afb1dd8cad0de Mon Sep 17 00:00:00 2001 From: Alan Alpert Date: Tue, 4 Oct 2011 14:17:50 +1000 Subject: [PATCH] Update particles autotests to not use SRCDIR Change-Id: I1b508756ffca6a05d495c52d84f46fcaeafe8797 Reviewed-on: http://codereview.qt-project.org/5947 Reviewed-by: Qt Sanity Bot Reviewed-by: Rohan McGovern --- tests/auto/particles/qsgage/qsgage.pro | 4 +++- tests/auto/particles/qsgage/tst_qsgage.cpp | 8 ++++---- tests/auto/particles/qsgangleddirection/qsgangleddirection.pro | 4 +++- .../auto/particles/qsgangleddirection/tst_qsgangleddirection.cpp | 2 +- .../particles/qsgcumulativedirection/qsgcumulativedirection.pro | 4 +++- .../qsgcumulativedirection/tst_qsgcumulativedirection.cpp | 2 +- tests/auto/particles/qsgcustomaffector/qsgcustomaffector.pro | 4 +++- tests/auto/particles/qsgcustomaffector/tst_qsgcustomaffector.cpp | 2 +- tests/auto/particles/qsgcustomparticle/qsgcustomparticle.pro | 4 +++- tests/auto/particles/qsgcustomparticle/tst_qsgcustomparticle.cpp | 2 +- tests/auto/particles/qsgellipseextruder/qsgellipseextruder.pro | 4 +++- .../auto/particles/qsgellipseextruder/tst_qsgellipseextruder.cpp | 2 +- tests/auto/particles/qsgfriction/qsgfriction.pro | 4 +++- tests/auto/particles/qsgfriction/tst_qsgfriction.cpp | 2 +- tests/auto/particles/qsggravity/qsggravity.pro | 4 +++- tests/auto/particles/qsggravity/tst_qsggravity.cpp | 2 +- tests/auto/particles/qsgimageparticle/qsgimageparticle.pro | 4 +++- tests/auto/particles/qsgimageparticle/tst_qsgimageparticle.cpp | 2 +- tests/auto/particles/qsgitemparticle/qsgitemparticle.pro | 4 +++- tests/auto/particles/qsgitemparticle/tst_qsgitemparticle.cpp | 2 +- tests/auto/particles/qsglineextruder/qsglineextruder.pro | 4 +++- tests/auto/particles/qsglineextruder/tst_qsglineextruder.cpp | 2 +- tests/auto/particles/qsgmaskextruder/qsgmaskextruder.pro | 4 +++- tests/auto/particles/qsgmaskextruder/tst_qsgmaskextruder.cpp | 2 +- tests/auto/particles/qsgparticlegroup/qsgparticlegroup.pro | 4 +++- tests/auto/particles/qsgparticlegroup/tst_qsgparticlegroup.cpp | 2 +- tests/auto/particles/qsgparticlesystem/qsgparticlesystem.pro | 4 +++- tests/auto/particles/qsgparticlesystem/tst_qsgparticlesystem.cpp | 2 +- tests/auto/particles/qsgpointattractor/qsgpointattractor.pro | 4 +++- tests/auto/particles/qsgpointattractor/tst_qsgpointattractor.cpp | 2 +- tests/auto/particles/qsgpointdirection/qsgpointdirection.pro | 4 +++- tests/auto/particles/qsgpointdirection/tst_qsgpointdirection.cpp | 2 +- .../auto/particles/qsgrectangleextruder/qsgrectangleextruder.pro | 4 +++- .../particles/qsgrectangleextruder/tst_qsgrectangleextruder.cpp | 2 +- tests/auto/particles/qsgtargetdirection/qsgtargetdirection.pro | 4 +++- .../auto/particles/qsgtargetdirection/tst_qsgtargetdirection.cpp | 2 +- tests/auto/particles/qsgtrailemitter/qsgtrailemitter.pro | 4 +++- tests/auto/particles/qsgtrailemitter/tst_qsgtrailemitter.cpp | 2 +- tests/auto/particles/qsgturbulence/qsgturbulence.pro | 4 +++- tests/auto/particles/qsgturbulence/tst_qsgturbulence.cpp | 2 +- tests/auto/particles/qsgwander/qsgwander.pro | 4 +++- tests/auto/particles/qsgwander/tst_qsgwander.cpp | 2 +- 42 files changed, 87 insertions(+), 45 deletions(-) diff --git a/tests/auto/particles/qsgage/qsgage.pro b/tests/auto/particles/qsgage/qsgage.pro index 3ca0740..17b3b13 100644 --- a/tests/auto/particles/qsgage/qsgage.pro +++ b/tests/auto/particles/qsgage/qsgage.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgage.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgage/tst_qsgage.cpp b/tests/auto/particles/qsgage/tst_qsgage.cpp index 884c210..d595e6e 100644 --- a/tests/auto/particles/qsgage/tst_qsgage.cpp +++ b/tests/auto/particles/qsgage/tst_qsgage.cpp @@ -62,7 +62,7 @@ tst_qsgage::tst_qsgage() void tst_qsgage::test_kill() { - QSGView* view = createView(SRCDIR "/data/kill.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/kill.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); @@ -82,7 +82,7 @@ void tst_qsgage::test_kill() void tst_qsgage::test_jump() { - QSGView* view = createView(SRCDIR "/data/jump.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/jump.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); @@ -103,7 +103,7 @@ void tst_qsgage::test_jump() void tst_qsgage::test_onceOff() { - QSGView* view = createView(SRCDIR "/data/onceoff.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/onceoff.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); @@ -125,7 +125,7 @@ void tst_qsgage::test_onceOff() void tst_qsgage::test_sustained() { - QSGView* view = createView(SRCDIR "/data/sustained.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/sustained.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgangleddirection/qsgangleddirection.pro b/tests/auto/particles/qsgangleddirection/qsgangleddirection.pro index a90b00b..5c055a4 100644 --- a/tests/auto/particles/qsgangleddirection/qsgangleddirection.pro +++ b/tests/auto/particles/qsgangleddirection/qsgangleddirection.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgangleddirection.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgangleddirection/tst_qsgangleddirection.cpp b/tests/auto/particles/qsgangleddirection/tst_qsgangleddirection.cpp index 0cc2c8b..4e65fa4 100644 --- a/tests/auto/particles/qsgangleddirection/tst_qsgangleddirection.cpp +++ b/tests/auto/particles/qsgangleddirection/tst_qsgangleddirection.cpp @@ -60,7 +60,7 @@ tst_qsgangleddirection::tst_qsgangleddirection() void tst_qsgangleddirection::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgcumulativedirection/qsgcumulativedirection.pro b/tests/auto/particles/qsgcumulativedirection/qsgcumulativedirection.pro index 03d9ca2..fdfee46 100644 --- a/tests/auto/particles/qsgcumulativedirection/qsgcumulativedirection.pro +++ b/tests/auto/particles/qsgcumulativedirection/qsgcumulativedirection.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgcumulativedirection.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgcumulativedirection/tst_qsgcumulativedirection.cpp b/tests/auto/particles/qsgcumulativedirection/tst_qsgcumulativedirection.cpp index 0c54ad8..1c4e98c 100644 --- a/tests/auto/particles/qsgcumulativedirection/tst_qsgcumulativedirection.cpp +++ b/tests/auto/particles/qsgcumulativedirection/tst_qsgcumulativedirection.cpp @@ -59,7 +59,7 @@ tst_qsgcumulativedirection::tst_qsgcumulativedirection() void tst_qsgcumulativedirection::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgcustomaffector/qsgcustomaffector.pro b/tests/auto/particles/qsgcustomaffector/qsgcustomaffector.pro index 1484491..91b4e73 100644 --- a/tests/auto/particles/qsgcustomaffector/qsgcustomaffector.pro +++ b/tests/auto/particles/qsgcustomaffector/qsgcustomaffector.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgcustomaffector.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgcustomaffector/tst_qsgcustomaffector.cpp b/tests/auto/particles/qsgcustomaffector/tst_qsgcustomaffector.cpp index 6ae2aa5..ec86fc7 100644 --- a/tests/auto/particles/qsgcustomaffector/tst_qsgcustomaffector.cpp +++ b/tests/auto/particles/qsgcustomaffector/tst_qsgcustomaffector.cpp @@ -59,7 +59,7 @@ tst_qsgcustomaffector::tst_qsgcustomaffector() void tst_qsgcustomaffector::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgcustomparticle/qsgcustomparticle.pro b/tests/auto/particles/qsgcustomparticle/qsgcustomparticle.pro index a151daf..d963c13 100644 --- a/tests/auto/particles/qsgcustomparticle/qsgcustomparticle.pro +++ b/tests/auto/particles/qsgcustomparticle/qsgcustomparticle.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgcustomparticle.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgcustomparticle/tst_qsgcustomparticle.cpp b/tests/auto/particles/qsgcustomparticle/tst_qsgcustomparticle.cpp index 74ef8af..01d557d 100644 --- a/tests/auto/particles/qsgcustomparticle/tst_qsgcustomparticle.cpp +++ b/tests/auto/particles/qsgcustomparticle/tst_qsgcustomparticle.cpp @@ -59,7 +59,7 @@ tst_qsgcustomparticle::tst_qsgcustomparticle() void tst_qsgcustomparticle::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QVERIFY(view); QSGParticleSystem* system = view->rootObject()->findChild("system"); diff --git a/tests/auto/particles/qsgellipseextruder/qsgellipseextruder.pro b/tests/auto/particles/qsgellipseextruder/qsgellipseextruder.pro index 5315686..8bdb2f1 100644 --- a/tests/auto/particles/qsgellipseextruder/qsgellipseextruder.pro +++ b/tests/auto/particles/qsgellipseextruder/qsgellipseextruder.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgellipseextruder.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgellipseextruder/tst_qsgellipseextruder.cpp b/tests/auto/particles/qsgellipseextruder/tst_qsgellipseextruder.cpp index f398936..a5aa91b 100644 --- a/tests/auto/particles/qsgellipseextruder/tst_qsgellipseextruder.cpp +++ b/tests/auto/particles/qsgellipseextruder/tst_qsgellipseextruder.cpp @@ -75,7 +75,7 @@ bool tst_qsgellipseextruder::inCircle(qreal x, qreal y, qreal r, bool borderOnly void tst_qsgellipseextruder::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); //Filled diff --git a/tests/auto/particles/qsgfriction/qsgfriction.pro b/tests/auto/particles/qsgfriction/qsgfriction.pro index a56f4b4..6793006 100644 --- a/tests/auto/particles/qsgfriction/qsgfriction.pro +++ b/tests/auto/particles/qsgfriction/qsgfriction.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgfriction.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgfriction/tst_qsgfriction.cpp b/tests/auto/particles/qsgfriction/tst_qsgfriction.cpp index 8981275..c56e004 100644 --- a/tests/auto/particles/qsgfriction/tst_qsgfriction.cpp +++ b/tests/auto/particles/qsgfriction/tst_qsgfriction.cpp @@ -59,7 +59,7 @@ tst_qsgfriction::tst_qsgfriction() void tst_qsgfriction::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); //Default is just slowed a little diff --git a/tests/auto/particles/qsggravity/qsggravity.pro b/tests/auto/particles/qsggravity/qsggravity.pro index d7a7bbd..3f68b4e 100644 --- a/tests/auto/particles/qsggravity/qsggravity.pro +++ b/tests/auto/particles/qsggravity/qsggravity.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsggravity.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsggravity/tst_qsggravity.cpp b/tests/auto/particles/qsggravity/tst_qsggravity.cpp index 584ec18..e99aa1e 100644 --- a/tests/auto/particles/qsggravity/tst_qsggravity.cpp +++ b/tests/auto/particles/qsggravity/tst_qsggravity.cpp @@ -59,7 +59,7 @@ tst_qsggravity::tst_qsggravity() void tst_qsggravity::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgimageparticle/qsgimageparticle.pro b/tests/auto/particles/qsgimageparticle/qsgimageparticle.pro index d1197f0..5563ecd 100644 --- a/tests/auto/particles/qsgimageparticle/qsgimageparticle.pro +++ b/tests/auto/particles/qsgimageparticle/qsgimageparticle.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgimageparticle.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgimageparticle/tst_qsgimageparticle.cpp b/tests/auto/particles/qsgimageparticle/tst_qsgimageparticle.cpp index 5e6e77c..423e842 100644 --- a/tests/auto/particles/qsgimageparticle/tst_qsgimageparticle.cpp +++ b/tests/auto/particles/qsgimageparticle/tst_qsgimageparticle.cpp @@ -59,7 +59,7 @@ tst_qsgimageparticle::tst_qsgimageparticle() void tst_qsgimageparticle::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgitemparticle/qsgitemparticle.pro b/tests/auto/particles/qsgitemparticle/qsgitemparticle.pro index e2d2c67..fd3eac9 100644 --- a/tests/auto/particles/qsgitemparticle/qsgitemparticle.pro +++ b/tests/auto/particles/qsgitemparticle/qsgitemparticle.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgitemparticle.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgitemparticle/tst_qsgitemparticle.cpp b/tests/auto/particles/qsgitemparticle/tst_qsgitemparticle.cpp index 440ebaf..2d18764 100644 --- a/tests/auto/particles/qsgitemparticle/tst_qsgitemparticle.cpp +++ b/tests/auto/particles/qsgitemparticle/tst_qsgitemparticle.cpp @@ -60,7 +60,7 @@ tst_qsgitemparticle::tst_qsgitemparticle() void tst_qsgitemparticle::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsglineextruder/qsglineextruder.pro b/tests/auto/particles/qsglineextruder/qsglineextruder.pro index ccafa70..243c441 100644 --- a/tests/auto/particles/qsglineextruder/qsglineextruder.pro +++ b/tests/auto/particles/qsglineextruder/qsglineextruder.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsglineextruder.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsglineextruder/tst_qsglineextruder.cpp b/tests/auto/particles/qsglineextruder/tst_qsglineextruder.cpp index 6a7cfe4..602985b 100644 --- a/tests/auto/particles/qsglineextruder/tst_qsglineextruder.cpp +++ b/tests/auto/particles/qsglineextruder/tst_qsglineextruder.cpp @@ -59,7 +59,7 @@ tst_qsglineextruder::tst_qsglineextruder() void tst_qsglineextruder::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgmaskextruder/qsgmaskextruder.pro b/tests/auto/particles/qsgmaskextruder/qsgmaskextruder.pro index 8cd5302..f04e61e 100644 --- a/tests/auto/particles/qsgmaskextruder/qsgmaskextruder.pro +++ b/tests/auto/particles/qsgmaskextruder/qsgmaskextruder.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgmaskextruder.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgmaskextruder/tst_qsgmaskextruder.cpp b/tests/auto/particles/qsgmaskextruder/tst_qsgmaskextruder.cpp index 1ac33a0..483ad93 100644 --- a/tests/auto/particles/qsgmaskextruder/tst_qsgmaskextruder.cpp +++ b/tests/auto/particles/qsgmaskextruder/tst_qsgmaskextruder.cpp @@ -59,7 +59,7 @@ tst_qsgmaskextruder::tst_qsgmaskextruder() void tst_qsgmaskextruder::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgparticlegroup/qsgparticlegroup.pro b/tests/auto/particles/qsgparticlegroup/qsgparticlegroup.pro index 40e799d..ff23437 100644 --- a/tests/auto/particles/qsgparticlegroup/qsgparticlegroup.pro +++ b/tests/auto/particles/qsgparticlegroup/qsgparticlegroup.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgparticlegroup.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgparticlegroup/tst_qsgparticlegroup.cpp b/tests/auto/particles/qsgparticlegroup/tst_qsgparticlegroup.cpp index 21eb52b..5cf170c 100644 --- a/tests/auto/particles/qsgparticlegroup/tst_qsgparticlegroup.cpp +++ b/tests/auto/particles/qsgparticlegroup/tst_qsgparticlegroup.cpp @@ -59,7 +59,7 @@ tst_qsgparticlegroup::tst_qsgparticlegroup() void tst_qsgparticlegroup::test_instantTransition() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); //A frame or two worth of particles will be missed, the transition doesn't take effect on the frame it's spawned (QTBUG-21781) diff --git a/tests/auto/particles/qsgparticlesystem/qsgparticlesystem.pro b/tests/auto/particles/qsgparticlesystem/qsgparticlesystem.pro index 6ba836a..525ecb8 100644 --- a/tests/auto/particles/qsgparticlesystem/qsgparticlesystem.pro +++ b/tests/auto/particles/qsgparticlesystem/qsgparticlesystem.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgparticlesystem.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgparticlesystem/tst_qsgparticlesystem.cpp b/tests/auto/particles/qsgparticlesystem/tst_qsgparticlesystem.cpp index d5a0a2a..cf00a00 100644 --- a/tests/auto/particles/qsgparticlesystem/tst_qsgparticlesystem.cpp +++ b/tests/auto/particles/qsgparticlesystem/tst_qsgparticlesystem.cpp @@ -59,7 +59,7 @@ tst_qsgparticlesystem::tst_qsgparticlesystem() void tst_qsgparticlesystem::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgpointattractor/qsgpointattractor.pro b/tests/auto/particles/qsgpointattractor/qsgpointattractor.pro index b2acf47..b112dcd 100644 --- a/tests/auto/particles/qsgpointattractor/qsgpointattractor.pro +++ b/tests/auto/particles/qsgpointattractor/qsgpointattractor.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgpointattractor.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgpointattractor/tst_qsgpointattractor.cpp b/tests/auto/particles/qsgpointattractor/tst_qsgpointattractor.cpp index 33fc670..40877c4 100644 --- a/tests/auto/particles/qsgpointattractor/tst_qsgpointattractor.cpp +++ b/tests/auto/particles/qsgpointattractor/tst_qsgpointattractor.cpp @@ -59,7 +59,7 @@ tst_qsgpointattractor::tst_qsgpointattractor() void tst_qsgpointattractor::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgpointdirection/qsgpointdirection.pro b/tests/auto/particles/qsgpointdirection/qsgpointdirection.pro index 6a02503..52e970f 100644 --- a/tests/auto/particles/qsgpointdirection/qsgpointdirection.pro +++ b/tests/auto/particles/qsgpointdirection/qsgpointdirection.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgpointdirection.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgpointdirection/tst_qsgpointdirection.cpp b/tests/auto/particles/qsgpointdirection/tst_qsgpointdirection.cpp index 89d0f31..56ef9cb 100644 --- a/tests/auto/particles/qsgpointdirection/tst_qsgpointdirection.cpp +++ b/tests/auto/particles/qsgpointdirection/tst_qsgpointdirection.cpp @@ -59,7 +59,7 @@ tst_qsgpointdirection::tst_qsgpointdirection() void tst_qsgpointdirection::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgrectangleextruder/qsgrectangleextruder.pro b/tests/auto/particles/qsgrectangleextruder/qsgrectangleextruder.pro index 207aa13..5b04c64 100644 --- a/tests/auto/particles/qsgrectangleextruder/qsgrectangleextruder.pro +++ b/tests/auto/particles/qsgrectangleextruder/qsgrectangleextruder.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgrectangleextruder.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgrectangleextruder/tst_qsgrectangleextruder.cpp b/tests/auto/particles/qsgrectangleextruder/tst_qsgrectangleextruder.cpp index 1e45f81..80def8b 100644 --- a/tests/auto/particles/qsgrectangleextruder/tst_qsgrectangleextruder.cpp +++ b/tests/auto/particles/qsgrectangleextruder/tst_qsgrectangleextruder.cpp @@ -59,7 +59,7 @@ tst_qsgrectangleextruder::tst_qsgrectangleextruder() void tst_qsgrectangleextruder::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgtargetdirection/qsgtargetdirection.pro b/tests/auto/particles/qsgtargetdirection/qsgtargetdirection.pro index 397957e..c6959b3 100644 --- a/tests/auto/particles/qsgtargetdirection/qsgtargetdirection.pro +++ b/tests/auto/particles/qsgtargetdirection/qsgtargetdirection.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgtargetdirection.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgtargetdirection/tst_qsgtargetdirection.cpp b/tests/auto/particles/qsgtargetdirection/tst_qsgtargetdirection.cpp index c5d84f5..642ef28 100644 --- a/tests/auto/particles/qsgtargetdirection/tst_qsgtargetdirection.cpp +++ b/tests/auto/particles/qsgtargetdirection/tst_qsgtargetdirection.cpp @@ -59,7 +59,7 @@ tst_qsgtargetdirection::tst_qsgtargetdirection() void tst_qsgtargetdirection::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgtrailemitter/qsgtrailemitter.pro b/tests/auto/particles/qsgtrailemitter/qsgtrailemitter.pro index 914d0e5..3a9c66a 100644 --- a/tests/auto/particles/qsgtrailemitter/qsgtrailemitter.pro +++ b/tests/auto/particles/qsgtrailemitter/qsgtrailemitter.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgtrailemitter.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgtrailemitter/tst_qsgtrailemitter.cpp b/tests/auto/particles/qsgtrailemitter/tst_qsgtrailemitter.cpp index a92b791..e6073ef 100644 --- a/tests/auto/particles/qsgtrailemitter/tst_qsgtrailemitter.cpp +++ b/tests/auto/particles/qsgtrailemitter/tst_qsgtrailemitter.cpp @@ -59,7 +59,7 @@ tst_qsgtrailemitter::tst_qsgtrailemitter() void tst_qsgtrailemitter::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); diff --git a/tests/auto/particles/qsgturbulence/qsgturbulence.pro b/tests/auto/particles/qsgturbulence/qsgturbulence.pro index 1c38cda..f179fea 100644 --- a/tests/auto/particles/qsgturbulence/qsgturbulence.pro +++ b/tests/auto/particles/qsgturbulence/qsgturbulence.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgturbulence.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgturbulence/tst_qsgturbulence.cpp b/tests/auto/particles/qsgturbulence/tst_qsgturbulence.cpp index c7feb3c..202de29 100644 --- a/tests/auto/particles/qsgturbulence/tst_qsgturbulence.cpp +++ b/tests/auto/particles/qsgturbulence/tst_qsgturbulence.cpp @@ -59,7 +59,7 @@ tst_qsgturbulence::tst_qsgturbulence() void tst_qsgturbulence::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); //Note that the noise image built-in provides the 'randomness', so this test should be stable so long as it and the size diff --git a/tests/auto/particles/qsgwander/qsgwander.pro b/tests/auto/particles/qsgwander/qsgwander.pro index b8bb4ae..5be0083 100644 --- a/tests/auto/particles/qsgwander/qsgwander.pro +++ b/tests/auto/particles/qsgwander/qsgwander.pro @@ -3,7 +3,9 @@ contains(QT_CONFIG,declarative): QT += declarative SOURCES += tst_qsgwander.cpp macx:CONFIG -= app_bundle -DEFINES += SRCDIR=\\\"$$PWD\\\" +testDataFiles.files = data +testDataFiles.path = . +DEPLOYMENT += testDataFiles CONFIG += parallel_test diff --git a/tests/auto/particles/qsgwander/tst_qsgwander.cpp b/tests/auto/particles/qsgwander/tst_qsgwander.cpp index 24b718c..6e7bc17 100644 --- a/tests/auto/particles/qsgwander/tst_qsgwander.cpp +++ b/tests/auto/particles/qsgwander/tst_qsgwander.cpp @@ -59,7 +59,7 @@ tst_qsgwander::tst_qsgwander() void tst_qsgwander::test_basic() { - QSGView* view = createView(SRCDIR "/data/basic.qml", 600); + QSGView* view = createView(QCoreApplication::applicationDirPath() + "/data/basic.qml", 600); QSGParticleSystem* system = view->rootObject()->findChild("system"); QCOMPARE(system->groupData[0]->size(), 500); -- 2.7.4