diff options
author | Paul Lemire <paul.lemire@kdab.com> | 2016-08-29 12:58:44 +0200 |
---|---|---|
committer | Sean Harmer <sean.harmer@kdab.com> | 2016-11-19 18:32:27 +0000 |
commit | b4a680a587cbbbcc2e11e2da8d9acd08f5b56d7c (patch) | |
tree | 2d0f47a9cfaee43ede4ceaf2bc864eb08884d6a6 /tests/auto/input | |
parent | bb8e5a6d4d43b57ed7eefc35cd25f333dbc9e298 (diff) |
PhysicalDeviceProxy: store id of loaded device
Change-Id: I467129355475cdf114ff7003708023c029eb73bc
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'tests/auto/input')
-rw-r--r-- | tests/auto/input/physicaldeviceproxy/tst_physicaldeviceproxy.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/auto/input/physicaldeviceproxy/tst_physicaldeviceproxy.cpp b/tests/auto/input/physicaldeviceproxy/tst_physicaldeviceproxy.cpp index 175137891..e4d384dba 100644 --- a/tests/auto/input/physicaldeviceproxy/tst_physicaldeviceproxy.cpp +++ b/tests/auto/input/physicaldeviceproxy/tst_physicaldeviceproxy.cpp @@ -54,6 +54,7 @@ private Q_SLOTS: QVERIFY(backendPhysicalDeviceProxy.peerId().isNull()); QCOMPARE(backendPhysicalDeviceProxy.deviceName(), QString()); QVERIFY(backendPhysicalDeviceProxy.manager() == nullptr); + QVERIFY(backendPhysicalDeviceProxy.physicalDeviceId().isNull()); } void checkInitializeFromPeer() @@ -73,6 +74,7 @@ private Q_SLOTS: QCOMPARE(backendPhysicalDeviceProxy.peerId(), PhysicalDeviceProxy.id()); QCOMPARE(backendPhysicalDeviceProxy.deviceName(), QStringLiteral("TestProxy")); QVERIFY(backendPhysicalDeviceProxy.manager() == &manager); + QVERIFY(backendPhysicalDeviceProxy.physicalDeviceId().isNull()); } { // WHEN @@ -123,6 +125,7 @@ private Q_SLOTS: QCOMPARE(change->propertyName(), "device"); QCOMPARE(change->value().value<Qt3DInput::QAbstractPhysicalDevice *>(), &physicalDevice); QCOMPARE(change->subjectId(), backendPhysicalDeviceProxy.peerId()); + QCOMPARE(backendPhysicalDeviceProxy.physicalDeviceId(), physicalDevice.id()); } void checkCleanupState() @@ -142,6 +145,7 @@ private Q_SLOTS: QCOMPARE(backendPhysicalDeviceProxy.isEnabled(), false); QCOMPARE(backendPhysicalDeviceProxy.deviceName(), QString()); QVERIFY(backendPhysicalDeviceProxy.manager() == nullptr); + QVERIFY(backendPhysicalDeviceProxy.physicalDeviceId().isNull()); } }; |