summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* QBluetoothDeviceDiscoveryAgent::DiscoveryMethod - autotestTimur Pocheptsov2016-08-011-0/+130
| | | | | | | | Add an auto-test for the recently introduced discovery methods. Task-number: QTBUG-46253 Change-Id: I264e0a0623284d329e18e30cf517cd1278693c44 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Add unit test for QBDDAgent::setLowEnergyDiscoveryTimeout()Alex Blasche2016-07-082-0/+85
| | | | | | Task-number: QTBUG-53012 Change-Id: I8910986ac3bc51cabc37aa509ef395972d88a7c5 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
* Merge remote-tracking branch 'gerrit/5.6' into 5.7Alex Blasche2016-05-231-2/+2
|\ | | | | | | Change-Id: I33cfb293df15c82247561d3540a4513cdf63b910
| * tst_qlowenergycontroller.cpp: Fixed typoOliver Wolff2016-05-201-1/+1
| | | | | | | | | | Change-Id: Ib6dc3ae3237f4dfcb158f053276ffc4e378acf43 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * tst_qlowenergycontroller: Fixed condition for IOSOliver Wolff2016-05-201-1/+1
| | | | | | | | | | Change-Id: I92e3b8f6b3a9a80d0e59040e15c60062e1f49cc2 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
* | Fix endianness conversion order bug when handling 128bit Qt UuidAlex Blasche2016-05-182-9/+49
| | | | | | | | | | | | | | | | | | | | QBluetoothUuid.toUInt128() always returns big endian notation. We have to convert it to host order before we convert to Bluetooth order. Task-number: QTBUG-53421 Change-Id: Ibab4f06fa70739adb163523c803a203608454427 Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-05-062-3/+2
|\| | | | | | | | | | | | | Conflicts: examples/nfc/corkboard/corkboard.pro Change-Id: I5d1ea0a8e21a1b55dbf744c2f4b469bc51f05c7a
| * Increase test coverage in bttestuiAlex Blasche2016-04-281-1/+1
| | | | | | | | | | | | | | | | | | | | QBluetoothSocket::connectDevice(QBluetoothServiceInfo, OpenMode) was not used so far. This call is even more efficient as it can avoid a complete service discovery. In summary quicker testing can be achieved. Change-Id: I6f9ef9eec6b773b9b90bf46e24a07878d81633cd Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * Peripheral Privacy Flag (0x2A02) may not be writable on some platformsAlex Blasche2016-04-271-2/+1
| | | | | | | | | | Change-Id: Ic80fe48fb192ee66f87aabcebc2b84e4ed3049a0 Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | Remove the traces of the discontinued android-no-sdk platformEirik Aavitsland2016-04-292-2/+2
| | | | | | | | | | Change-Id: I0358b76dd2b9fb2a6224c4b9b2082a748b2d5d7a Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* | Fix QLEServiceData comparison operator inconsistencyAlex Blasche2016-03-091-0/+14
| | | | | | | | | | | | | | | | The comparison operators usually have const& parameters. Change-Id: Ibd8e7d1fe5704b4de3a0bfabe1bbc991411eecba Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com> Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | Bluetooth LE: Add support for Signed Write command in the central role.Christian Kandeler2016-02-172-6/+52
| | | | | | | | | | | | Task-number: QTBUG-41175 Change-Id: I62d74236faf9161681306d952e409e23e0cea24d Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Fix undefined behavior in AddressInfo's default ctor.Alex Blasche2016-02-111-0/+5
| | | | | | | | | | | | | | The AddressInfo::type member was not properly initialised. Change-Id: I79c8e1d00d4cb03e3d073a23bb4dbf6b9d510b7c Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | Bluetooth LE: Fix two list setter functions.Christian Kandeler2016-02-091-0/+8
| | | | | | | | | | | | | | | | Adding the new list elements is all well and nice, but we have to clear the existing ones first. Change-Id: I1b044f2ea86a4a300bde93535a944c18328aa805 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Bluetooth LE: Add configure test for Linux crypto API.Christian Kandeler2016-02-092-2/+4
| | | | | | | | | | | | | | These files were forgotten in commit c516f6157a. Change-Id: I87bd57545b8873fc0aa00751058be604588daffe Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Bluetooth LE: Add support for Signed Write command.Christian Kandeler2016-02-033-2/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - This is how we get at the signature resolving key: 1) On connection from a client, we read the key from the respective BlueZ settings file (BlueZ 5 only, as I did not manage to find out where BlueZ 4 keeps this information). 2) Also monitor the HCI traffic for key updates (due to re-pairing). - While there is an autotest for the actual hashing procedure, the overall feature cannot be easily tested for various reasons (there is no signed write support in our client API, for one). However, to help with manual testing, the server part of our autotest now exposes a characteristic that supports signed writes. - This feature requires a Linux kernel >= 3.7. Change-Id: I7ede9b430de167fe1f4519eedf8670d88d79aa25 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Update to new Qt license headersneardAlex Blasche2016-01-262-34/+24
| | | | | | | | | | Change-Id: I2c799dbac99c66d5e87fd92efc215e121064cfde Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
* | Merge remote-tracking branch 'gerrit/dev' into neardAlex Blasche2016-01-2627-461/+326
|\ \ | | | | | | | | | Change-Id: If9cf6718cbd619dd7ce38db2da274fe9d0a41fb7
| * | Updated license headersAntti Kokko2016-01-2027-461/+326
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I37338c968d8cb5a056cd42e1130cfa077b12d164 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | | Bluetooth LE: Add connection update functionality.Christian Kandeler2016-01-182-0/+33
| | | | | | | | | | | | | | | | | | | | | Implemented for BlueZ only. Change-Id: I358a98bbc7499d5ce5437fb0d4672fde46c3b831 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Merge remote-tracking branch 'gerrit/dev' into neardAlex Blasche2016-01-051-3/+3
|\| | | | | | | | | | | | | | | | | | | | Conflicts: src/bluetooth/qlowenergycontroller.cpp Change-Id: I28b116deb3fa87169432eb2d94b70894359a9057
| * | tvOS supportMike Krus2016-01-051-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Builds but not tested Moved Q_DECLARE_METATYPE outside of namespace to fix namespaced builds Change-Id: I19c1dba904da8fad155f0f612b863e8f5e0c422e Reviewed-by: James Turner <james.turner@kdab.com> Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth: Fix endianness issues in GATT server autotest.Christian Kandeler2015-12-162-10/+12
| | | | | | | | | | | | | | | Change-Id: Ifac43c3799f87de7ed0ea981ed7e229714f51584 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth LE: Implement GATT server write support.Christian Kandeler2015-12-152-11/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Write Request, Write Command and Execute Write Request are fully implemented now. Signed Write support is still missing. Notifications and Indications are sent. The server side gets informed via the respective signals when a client writes a characteristic or descriptor. Change-Id: Icba6a0270f6e1c4c3ed2ba61b55c1a5fbb69752b Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth LE: Implement ATT access permissions.Christian Kandeler2015-12-042-3/+35
| | | | | | | | | | | | | | | Change-Id: I456d083d45569ea8d61f0a659f72646d653143d1 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Merge remote-tracking branch 'gerrit/dev' into neardAlex Blasche2015-12-034-5/+0
|\| | | | | | | | | | | Change-Id: I1fc766d26aadb7cc01d33c4c8a2260411d7bb138
| * | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-12-014-5/+0
| |\| | | | | | | | | | Change-Id: Id2cf334af75d6a0804da7e0125ff7552c49f9ac4
| | * Bluetooth autotests - remove outdated insignificantTimur Pocheptsov2015-11-254-5/+0
| | | | | | | | | | | | | | | | | | | | | | | | Several tests were marked as 'insignificant' in the past, but nowadays tests can deal with VMs without BT adapters. Change-Id: If657b3723a9a3f88c9c638105a077fd7396931d8 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth: Partial implementation of GATT server functionality.Christian Kandeler2015-11-302-9/+205
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Available so far are all "read" and "find" requests (BlueZ only). Things left to do: - Access checks regarding authentication, authorization and encryption requirements. - Handling write requests. - Notifications and Indications. Change-Id: Idfcb863b1b375cd0414580b5ce1cba67c23a6bf8 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth: Add API to set up GATT services.Christian Kandeler2015-11-201-0/+92
| | | | | | | | | | | | | | | | | | | | | This is the next step in implementing LE peripheral support. Change-Id: I5e8cb186d556e7bfb9ae8a5e60e051ff7398b77d Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | | Bluetooth: Introduce API for LE advertising.Christian Kandeler2015-11-178-0/+250
|/ / | | | | | | | | | | | | And provide an implementation for BlueZ. Change-Id: I302aee7c43b77016d9e1e7a0d5bcbf00096abf76 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Tests: Remove QT_DISABLE_DEPRECATED_BEFORE=0.Friedemann Kleint2015-08-253-4/+0
| | | | | | | | | | | | | | Fix usage of API that is marked deprecated. Change-Id: I82fe0911f6783a709356211b001e1d377f694642 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Remove QT_DISABLE_DEPRECATED_BEFORE=0 from tests not using deprecated API.Friedemann Kleint2015-08-2515-15/+0
|/ | | | | Change-Id: I56709b173111ca52cc5c524ecf9ec72e25721f6a Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Add security flag support for tests with bttestuiAlex Blasche2015-07-063-3/+73
| | | | | | | | | | The user presses the "Cycle SecFlag" button and chooses the required sec level. The sec level is set on client and server socket shortly before connectToService() and listen() are called. Change-Id: Ic841fb22eb2acaf738435d6d34897b7efb59e22e Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Add test for QBluetoothSocket::preferredSecurityFlags() and setterAlex Blasche2015-07-062-1/+32
| | | | | | Task-number: QTBUG-46377 Change-Id: I12de86befe60c7d4167a6b630e3fddaf55863039 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-06-294-8/+0
|\ | | | | | | | | | | | | | | Conflicts: .qmake.conf src/nfc/doc/src/nfc-index.qdoc Change-Id: Ie12d3023ff934f6579ae93617c95fc654e85a7f0
| * Port from Q_ENUMS to new macro Q_ENUMKonstantin Ritt2015-06-234-8/+0
| | | | | | | | | | | | | | | | | | | | | | Remove Q_ENUMS in favor of the new Q_ENUM macro which provides registration as meta enum and a debug stream operator. Register some enums via Q_ENUM to improve debug output and types auto-registration. Change-Id: I31c9535a2de7da1783b4ec967612c02a57cb62ff Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Remove QNX/BlackBerry implementation for QtBluetoothAlex Blasche2015-06-175-15/+0
|/ | | | | | | | | [ChangeLog][QtBluetooth][Platform Specific Changes] Removed support for Blackberry 10. Change-Id: I431c4f34bb10aa3668542df7a8b3403b61bf4705 Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Test Q_DECLARE_OPERATORS_FOR_FLAGS operatorsAlex Blasche2015-05-284-1/+132
| | | | | | | | | This global operator was added to QBluetoothDeviceInfo and QLowEnergyService flags. Change-Id: Ic841cf8c08a2289a9c112dc6283c8891dcc8750e Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* Unit test for new QBluetoothHostInfo comparison operatorsAlex Blasche2015-05-271-0/+58
| | | | | Change-Id: I40ac86ccf94e8575220e6094dfec0d5537eba3a1 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Reduce platform specific code linesAlex Blasche2015-05-122-65/+46
| | | | | | | | | | | | QLEController(QBluetoothAddress) ctor is not usable on iOS and OSX. On those platforms we have to use QLECOntroller(QBluetoothDeviceInfo). We mark the QBluetoothAddress based ctors of QLEController obsolete and remove most uses of them. This cleans up some ifdefs throughout the QtBluetooth code base. Change-Id: Ibe1e3fa271a29461e39fc3c0eeba7a910a250077 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Make the QLEService unit test more error tolerantAlex Blasche2015-04-151-10/+11
| | | | | | | | | The service discovery sometimes takes longer than 10s on Adroid and there is really no point in testing the value of the System ID characteristic. This value is different for every device. Change-Id: Ib418e852e8a41db7483c5b47d2d0dc61f28b05b2 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Add tests for QLEService::readDescriptor()Alex Blasche2015-04-151-4/+31
| | | | | Change-Id: I84f6d76e89036d29f14f8ca326f3fa26e626ff63 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Add QLEService tests dealing with read and write error casesAlex Blasche2015-04-151-0/+230
| | | | | Change-Id: If3ea946371583b0011e6fb9533d4d5789db3739b Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Always read/write the GATT hardware even if meta data reports otherwiseAlex Blasche2015-04-151-2/+2
| | | | | | | | | | | | | | | | It is possible that a ATT attribute is not readable or writable. Usually this is reported via descriptors or other types of meta data. However it is possible that the meta data is reporting the wrong information. Therefore we always ensure that every read and write request is forwarded to the hardware. It is up to the hardware to respond to such requests. This change keeps the device usable in cases of buggy device meta data. This only affected writeCharacteristic() calls. Change-Id: Ieb2b95f47aa51c86a8ae7c4bebed4043d7478874 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com> Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Add writeCharacteristic() test to encrypted characteristicAlex Blasche2015-04-151-4/+26
| | | | | | | The test is not automatic and the right hardware setup is required. Change-Id: I6ad9115e21cbd826cfe647a66f5b58f56a380a6f Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Add tests for QLES::readCharacteristic()Alex Blasche2015-04-151-10/+138
| | | | | | | | | | | | | | | | | The following types of tests are performed: 1. reading of char value that fits into single ATT packet 2. reading of char value that is not readable 3. reading of char value that is requires two ATT packets (blob reads) 4. reading of char value that is exactly as long as one ATT packet (this is different than case 1 as it triggers blob reads where the the first blob read packaet is empty) Cases 1 & 2 are done using the TI Sensor Tag. Cases 3 & 4 require programmable CSR dev kit. Those tests are not enabled by default and require manual setup. Change-Id: I402a7369abbbde6b8309bed8bef6b9a9441cabc9 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
* Merge remote-tracking branch 'origin/5.4' into 5.5Frederik Gladhorn2015-02-248-0/+23331
|\ | | | | | | Change-Id: Ie5ce761b77cc5c02647a9f7d52f427401b85d6b0
| * bic: Add 5.{2,3,4}.0 bic data for QtBluetooth and QtNfcSergio Ahumada2015-02-178-0/+23331
| | | | | | | | | | | | Change-Id: I0b98c18e0943b250debcf6e5461ddb19fba024ab Reviewed-by: Liang Qi <liang.qi@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Update copyright headersJani Heikkinen2015-02-1626-181/+181
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I3822a6484e8f7a420330de1cb1aeb0c3d1cf41b7 Reviewed-by: Sergio Ahumada <sahumada@texla.cl>