diff options
author | Lorn Potter <lorn.potter@nokia.com> | 2010-12-15 10:29:04 +1000 |
---|---|---|
committer | Lorn Potter <lorn.potter@nokia.com> | 2010-12-15 10:29:04 +1000 |
commit | 1b3f8eea5091b4dcb9848c06ce03b8f38fa16fff (patch) | |
tree | de7111e3af9c1a8012429a93f3d7d7754cc39c34 | |
parent | 33b7161d8a9d94c264bc73e06c8503bb8b58c9e6 (diff) |
rename test_sim -> test_use_sim
17 files changed, 62 insertions, 30 deletions
@@ -110,7 +110,7 @@ QMKSPEC= OS="other" # By default, all modules are requested. Reset this later if -modules is supplied ORGANIZER_REQUESTED=yes -TEST_SIM= +TEST_USE_SIMULATOR= usage() { @@ -285,7 +285,7 @@ while [ "$#" -gt 0 ]; do shift ;; -test-sim) - TEST_SIM="yes" + TEST_USE_SIMULATOR="yes" ;; *) echo "Unknown option: $1" @@ -485,10 +485,10 @@ else echo "build_tools = yes" >> "$CONFIG_IN" fi -if [ -z "$TEST_SIM" ]; then - echo "test_sim = no" >> "$CONFIG_IN" +if [ -z "$TEST_USE_SIMULATOR" ]; then + echo "test_use_sim = no" >> "$CONFIG_IN" else - echo "test_sim = yes" >> "$CONFIG_IN" + echo "test_use_sim = yes" >> "$CONFIG_IN" fi echo "Configuring Qt Mobility" diff --git a/src/systeminfo/systeminfo.pro b/src/systeminfo/systeminfo.pro index a859afae65..e5bb4c77a3 100644 --- a/src/systeminfo/systeminfo.pro +++ b/src/systeminfo/systeminfo.pro @@ -67,7 +67,7 @@ unix:!simulator { !maemo5:!maemo6:linux-*: { - contains(build_unit_tests, yes):contains(test_sim, yes) { + contains(build_unit_tests, yes):contains(test_use_sim, yes) { SOURCES += qsysteminfo_simulator.cpp qsysteminfodata_simulator.cpp HEADERS += qsysteminfo_simulator_p.h qsysteminfodata_simulator_p.h DEFINES += TESTR QT_SIMULATOR diff --git a/tests/auto/qdeclarativebatteryinfo/qdeclarativebatteryinfo.pro b/tests/auto/qdeclarativebatteryinfo/qdeclarativebatteryinfo.pro index 76149cab13..26283c97e0 100644 --- a/tests/auto/qdeclarativebatteryinfo/qdeclarativebatteryinfo.pro +++ b/tests/auto/qdeclarativebatteryinfo/qdeclarativebatteryinfo.pro @@ -3,7 +3,6 @@ CONFIG+=testcase SOURCES += tst_qdeclarativebatteryinfo.cpp QT = core -#DEFINES += TESTR HEADERS += ../../../plugins/declarative/systeminfo/qdeclarativebatteryinfo_p.h SOURCES += ../../../plugins/declarative/systeminfo/qdeclarativebatteryinfo.cpp @@ -19,3 +18,7 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } + +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativedeviceinfo/qdeclarativedeviceinfo.pro b/tests/auto/qdeclarativedeviceinfo/qdeclarativedeviceinfo.pro index 9ba1e6c012..3bb3c9b0f8 100644 --- a/tests/auto/qdeclarativedeviceinfo/qdeclarativedeviceinfo.pro +++ b/tests/auto/qdeclarativedeviceinfo/qdeclarativedeviceinfo.pro @@ -20,3 +20,6 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativedisplayinfo/qdeclarativedisplayinfo.pro b/tests/auto/qdeclarativedisplayinfo/qdeclarativedisplayinfo.pro index 320b5ccc67..288eeacfc9 100644 --- a/tests/auto/qdeclarativedisplayinfo/qdeclarativedisplayinfo.pro +++ b/tests/auto/qdeclarativedisplayinfo/qdeclarativedisplayinfo.pro @@ -19,3 +19,6 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativenetworkinfo/qdeclarativenetworkinfo.pro b/tests/auto/qdeclarativenetworkinfo/qdeclarativenetworkinfo.pro index 809c352fee..e5f5e06acb 100644 --- a/tests/auto/qdeclarativenetworkinfo/qdeclarativenetworkinfo.pro +++ b/tests/auto/qdeclarativenetworkinfo/qdeclarativenetworkinfo.pro @@ -20,3 +20,6 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativescreensaver/qdeclarativescreensaver.pro b/tests/auto/qdeclarativescreensaver/qdeclarativescreensaver.pro index 418683970d..4b6c5310f0 100644 --- a/tests/auto/qdeclarativescreensaver/qdeclarativescreensaver.pro +++ b/tests/auto/qdeclarativescreensaver/qdeclarativescreensaver.pro @@ -19,3 +19,6 @@ symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativestorageinfo/qdeclarativestorageinfo.pro b/tests/auto/qdeclarativestorageinfo/qdeclarativestorageinfo.pro index 8b48b9ef87..210c58751e 100644 --- a/tests/auto/qdeclarativestorageinfo/qdeclarativestorageinfo.pro +++ b/tests/auto/qdeclarativestorageinfo/qdeclarativestorageinfo.pro @@ -25,3 +25,6 @@ symbian { } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qdeclarativesysteminfo/qdeclarativesysteminfo.pro b/tests/auto/qdeclarativesysteminfo/qdeclarativesysteminfo.pro index 89d8bd855f..e035099cee 100644 --- a/tests/auto/qdeclarativesysteminfo/qdeclarativesysteminfo.pro +++ b/tests/auto/qdeclarativesysteminfo/qdeclarativesysteminfo.pro @@ -20,3 +20,6 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystembatteryinfo/qsystembatteryinfo.pro b/tests/auto/qsystembatteryinfo/qsystembatteryinfo.pro index ccf258613f..b7c4b0ac63 100644 --- a/tests/auto/qsystembatteryinfo/qsystembatteryinfo.pro +++ b/tests/auto/qsystembatteryinfo/qsystembatteryinfo.pro @@ -3,7 +3,7 @@ CONFIG+=testcase SOURCES += tst_qsystembatteryinfo.cpp QT = core -DEFINES += TESTR + INCLUDEPATH += ../../../src/systeminfo include(../../../common.pri) @@ -13,3 +13,7 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } + +contains(test_use_sim, yes) { + DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystemdeviceinfo/qsystemdeviceinfo.pro b/tests/auto/qsystemdeviceinfo/qsystemdeviceinfo.pro index 7dabd6a1ed..f534943fe9 100644 --- a/tests/auto/qsystemdeviceinfo/qsystemdeviceinfo.pro +++ b/tests/auto/qsystemdeviceinfo/qsystemdeviceinfo.pro @@ -4,9 +4,6 @@ QT = core network INCLUDEPATH += ../../../src/systeminfo SOURCES += tst_qsystemdeviceinfo.cpp -contains(test_sim, yes) { -DEFINES += TESTR -} include(../../../common.pri) CONFIG += mobility MOBILITY = systeminfo @@ -14,3 +11,7 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +message($$test_use_sim) +contains(test_use_sim, yes) { + DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystemdeviceinfo/tst_qsystemdeviceinfo.cpp b/tests/auto/qsystemdeviceinfo/tst_qsystemdeviceinfo.cpp index 62ab6a9237..c8e2978762 100644 --- a/tests/auto/qsystemdeviceinfo/tst_qsystemdeviceinfo.cpp +++ b/tests/auto/qsystemdeviceinfo/tst_qsystemdeviceinfo.cpp @@ -92,7 +92,7 @@ public: d->setCurrentProfile(profile); d->setBluetoothPower(btPower); d->setWirelessKeyboardConnected(keyboardConnected); - d->setKeyboardFlipOpen(flip); + d->setKeyboardFlippedOpen(flip); d->setDeviceLocked(locked); d->setTypeOfLock(lockType); @@ -171,7 +171,7 @@ private slots: void tst_bluetoothStateChanged(); void tst_wirelessKeyboardConnected(); - void tst_keyboardFlip(); + void tst_keyboardFlipped(); void tst_deviceLocked(); void tst_lockTypeChanged_data(); @@ -185,7 +185,7 @@ private slots: void bluetoothStateChanged(bool on); void wirelessKeyboardConnected(bool connected); - void keyboardFlip(bool open); + void keyboardFlipped(bool open); void deviceLocked(bool isLocked); void lockStatusChanged(QSystemDeviceInfo::LockType); #endif @@ -607,21 +607,21 @@ void tst_QSystemDeviceInfo::tst_wirelessKeyboardConnected() } -void tst_QSystemDeviceInfo::tst_keyboardFlip() +void tst_QSystemDeviceInfo::tst_keyboardFlipped() { QSystemDeviceInfo di; SystemInfoConnection si; ChangeDeviceThread *changeDevThread = new ChangeDeviceThread(); - connect(&di,SIGNAL(keyboardFlip(bool)), - this,SLOT(keyboardFlip(bool))); + connect(&di,SIGNAL(keyboardFlipped(bool)), + this,SLOT(keyboardFlipped(bool))); changeDevThread->flip = keyFLip = true; changeDevThread->start(); - QSignalSpy errorSpy(&di, SIGNAL(keyboardFlip(bool))); - QVERIFY(::waitForSignal(&di, SIGNAL(keyboardFlip(bool)), 10 * 1000)); + QSignalSpy errorSpy(&di, SIGNAL(keyboardFlipped(bool))); + QVERIFY(::waitForSignal(&di, SIGNAL(keyboardFlipped(bool)), 10 * 1000)); QVERIFY(errorSpy.count() == 1); @@ -728,7 +728,7 @@ void tst_QSystemDeviceInfo::wirelessKeyboardConnected(bool connected) QVERIFY(connected == keyboardConnect); } -void tst_QSystemDeviceInfo::keyboardFlip(bool open) +void tst_QSystemDeviceInfo::keyboardFlipped(bool open) { QVERIFY(open == keyFLip); } diff --git a/tests/auto/qsystemdisplayinfo/qsystemdisplayinfo.pro b/tests/auto/qsystemdisplayinfo/qsystemdisplayinfo.pro index 4ddf7bf11c..c1fef89308 100644 --- a/tests/auto/qsystemdisplayinfo/qsystemdisplayinfo.pro +++ b/tests/auto/qsystemdisplayinfo/qsystemdisplayinfo.pro @@ -13,3 +13,6 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsysteminfo/qsysteminfo.pro b/tests/auto/qsysteminfo/qsysteminfo.pro index 5da16aa56e..e83a5a15fd 100644 --- a/tests/auto/qsysteminfo/qsysteminfo.pro +++ b/tests/auto/qsysteminfo/qsysteminfo.pro @@ -3,9 +3,6 @@ CONFIG+=testcase SOURCES += tst_qsysteminfo.cpp QT = core network -contains(test_sim, yes) { -DEFINES += TESTR -} INCLUDEPATH += ../../../src/systeminfo include(../../../common.pri) @@ -15,3 +12,7 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } + +contains(test_use_sim, yes) { + DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystemnetworkinfo/qsystemnetworkinfo.pro b/tests/auto/qsystemnetworkinfo/qsystemnetworkinfo.pro index f3c374078a..43b067a71c 100644 --- a/tests/auto/qsystemnetworkinfo/qsystemnetworkinfo.pro +++ b/tests/auto/qsystemnetworkinfo/qsystemnetworkinfo.pro @@ -5,9 +5,6 @@ QT = core network SOURCES += tst_qsystemnetworkinfo.cpp INCLUDEPATH += ../../../src/systeminfo -contains(test_sim, yes) { -DEFINES += TESTR QT_SIMULATOR -} include(../../../common.pri) CONFIG += mobility MOBILITY = systeminfo @@ -15,3 +12,7 @@ MOBILITY = systeminfo symbian { TARGET.CAPABILITY = All -TCB -DRM } + +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystemscreensaver/qsystemscreensaver.pro b/tests/auto/qsystemscreensaver/qsystemscreensaver.pro index d74ce9bfb5..5a98a01165 100644 --- a/tests/auto/qsystemscreensaver/qsystemscreensaver.pro +++ b/tests/auto/qsystemscreensaver/qsystemscreensaver.pro @@ -13,3 +13,6 @@ symbian { TARGET.CAPABILITY = All -TCB -DRM } +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR +} diff --git a/tests/auto/qsystemstorageinfo/qsystemstorageinfo.pro b/tests/auto/qsystemstorageinfo/qsystemstorageinfo.pro index 2de25cdf26..dfd52527da 100644 --- a/tests/auto/qsystemstorageinfo/qsystemstorageinfo.pro +++ b/tests/auto/qsystemstorageinfo/qsystemstorageinfo.pro @@ -15,8 +15,6 @@ symbian { } - - -contains(test_sim, yes) { - DEFINES += TESTR +contains(test_use_sim, yes) { +DEFINES += TESTR QT_SIMULATOR } |