summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Fix some typosSergio Ahumada2014-03-033-3/+3
| | | | | Change-Id: If46057e48040fda7b61b81e735c171daf2cc7d06 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Prefer to use normalised signal/slot signaturesSergio Ahumada2014-03-034-58/+58
| | | | | | Change-Id: I8425c141add90f58aefcf2b9706f9d6328382644 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* Bump all qml code to QtLocation 5.3Alex Blasche2014-02-2638-67/+67
| | | | | | | It is the baseline for all subsequent additions. Change-Id: Ia56da45b8b92dd0224dbeff97976cd06aa25d943 Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* Remove test code related to removed gestures.Aaron McCarthy2014-02-261-211/+4
| | | | | | | | Rotate and tilt gestures were recently removed. Some of the related test code was left in which is now failing. Change-Id: Iadb5b40cb5e2740f331453b673b89948fb829e51 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* Fix unstable PositionInfo test.Aaron McCarthy2014-02-261-3/+2
| | | | | | | | The speed reported by the position source can vary due to the system load and scheduling during the test. Increase the tolerence. Change-Id: I26c0e6a9c19cfe73f7c1c24b133dbd3cc5abc04e Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* Copy qmldir of test import to destination directory.Aaron McCarthy2014-02-252-0/+14
| | | | | | | | | | Test imports, used only during tests, are not installed prior to running tests. Copy the qmldir file to the output directory so that the tests can successfully load the import. Task-number: QTBUG-31797 Change-Id: I85095eb7532df6b1fc06f10e46ed8b4db41554a6 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* Add debug to test case.Aaron McCarthy2014-02-251-0/+1
| | | | | | | To help debug a test failure in CI. Change-Id: I2d8c8ac3e873c80bf6c4c317dfc0db19d7a1255a Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-02-127-2/+87
|\ | | | | | | Change-Id: I1de140f15e028425e888e6ef52d9f2ff11fd9d5b
| * Add QML test for comparing QtPositioning base types.old/5.2Aaron McCarthy2014-02-112-2/+47
| | | | | | | | | | | | | | | | Tests added for comparing Coordinate, Shape, Rectangle and Circle. Task-number: QTBUG-33561 Change-Id: Ie826f670e75b26ac43ad7cea7c9b108b01008f3d Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
| * Mark QNmeaPositionInfoSource tests as insignificant on Windows.Alex Blasche2014-02-105-0/+40
| | | | | | | | | | | | | | | | | | The local TCP socket required by these tests regularly fails on the Windows CI due to heavy load. Change-Id: I65e6150b8c735aec85e643cf1702344ff707723d Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Fix declarative_ui tests.Aaron McCarthy2014-02-114-28/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Coordinates for map items located outside the view port cannot be converted to and from screen coordinates. During tests pan the map so that the items under tests are inside the view port. Tests for panning the map and dragging map items were failing because mapping between coordinates and screen position only works for visible screen positions. The MouseAreas under test did not have preventStealing set, which was causing the map to pan slightly prior to item drag being detected. Stop gesture detection for a touch point when the mouse is grabbed by a child item. Task-number: QTBUG-31797 Change-Id: I42a801d50c194c6fe9629f3b0de606b406ad8b8c Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Test that the mapping manager engine pointer is still valid.Aaron McCarthy2014-02-101-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QPointer holds a guarded pointer to a QObject. It must always be tested prior to use. Changed the parameter type to remove the need for the static_cast when setting the QPointer member. The root cause was that the tile fetcher object was not being destroyed when the mapping manager engine was. Which was because the two objects were in different threads. Some of the service specific tile fetchers were directly calling into the engine objects across thread. Gah. Since Qt 5 QNAM uses an application global thread for processing requests, there is no need to use threads in the tile fetcher. Change-Id: Id9df35ddfa78df2cbf334006fe5fc9726a75f92d Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Add direction and vertical speed properties to QML Position type.Aaron McCarthy2014-02-103-2/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The QML and C++ position types now provide the same functionality. Position attributes are always set/reset on every position update. This ensures that old values of speed, accuracy, direction, and vertical speed are not indefinitely reported in QML. Values are set to NaN and if appropriate the associated is valid property is set. [ChangeLog][QtPositioning][Position] Added direction and vertical speed properities. Change-Id: Ia02da8a5bc1cd68489eb58180986df512c24aa2f Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Work around broken Map mouse tests.Aaron McCarthy2014-02-071-18/+23
| | | | | | | | | | | | | | | | Due to QTBUG-36560 some map mouse tests were failing. Implement a valid workaround until it is fix. Change-Id: Iec67f82d2e2a9792ed067b9cd956345ab38e7ab7 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Missing changes from MapMouseArea removal.Aaron McCarthy2014-02-063-15/+2
| | | | | | | | | | | | | | | | | | | | | | MapMouseArea has been removed. Remove MapMouseEvent, it is no longer required. Remove some remaining MapMouseArea instances in the tests. Change-Id: I12c534bb3360f6a19ec9e1dd40ecf7bb0d7b8e21 Reviewed-by: Fabian Bumberger <fbumberger@rim.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Remove the GeoMapMouseAreaFabian Bumberger2014-02-064-25/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I don't see a reason for keeping this. First of all, only half of it is implemented. Second we can have the same behavior with a normal MouseArea. The only advantage a MapMouseArea has is that mouse events are only received in the boundaries of the parent map item. However with a bit of work in the parent map item we can have this behavior as well for a normal mouse area. The only thing we are eventually loosing is the geocoordinate property of the MapMouseEvent. But this can be easily obtained with the "toCoordinate" function in the Map item. Change-Id: Icb176ee7d7c2881df714ab3191fa1f7f5c8915e2 Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Revert "Temporary workaround for failing unit test on win8 config in CI"Alex Blasche2014-02-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 93773ce48d3f884fbd71a6783d317bda1880bd37. The related bug was fixed in qtdeclarative (see c6da58a295235c89ee2a5847b15cb0b1dc66b2f4) Task-number: QTBUG-36519 Change-Id: I233d08f091fb3273f111d41c4743808d8aaf4637 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Fix QGeoRouteXmlParser test.Aaron McCarthy2014-02-041-2/+0
| | | | | | | | | | | | | | | | | | The TravelTime element is a double, which was failing to be parsed by QString::toInt(). Fixed by using QString::toDouble() and rounding the result. Change-Id: I012c277f1efdb3811a50eff96519a4d0d9959a67 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Reject negative number of alternative routes.Aaron McCarthy2014-02-041-1/+0
| | | | | | | | | | | | | | | | | | Requesting a negative number of alternative routes does not make sense. Fall back to the default value of 0 if a negative number of alternative routes is requested. Change-Id: Iecc1b7ba8bfa25b59b2a4c2efeafa33fd528377d Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Temporary workaround for failing unit test on win8 config in CIAlex Blasche2014-02-041-0/+1
| | | | | | | | | | | | Task-number: QTBUG-36519 Change-Id: I17a60fe311715bcd9b7e5e5253736daabff67caf Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* | Remove offset attribute from place content requests.Aaron McCarthy2014-01-2210-77/+85
| | | | | | | | | | | | | | | | | | | | | | | | This complements 1d0966c6924876655c52725e779a7aa24866ff60 Not all service providers support arbitrary offsets when requesting place content. The offset attribute has been removed, instead service providers can supply a previous and next content request query in the form of a QPlaceContentRequest. Change-Id: I6239b42c31bed5dcd6645d86d5a48d7e6a667f46 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Merge "Merge remote-tracking branch 'origin/stable' into dev" into ↵Alex Blasche2014-01-202-5/+21
|\ \ | | | | | | | | | refs/staging/dev
| * \ Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-01-172-5/+21
| |\ \ | | |/ | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/plugins/position/geoclue/qgeopositioninfosourcefactory_geoclue.cpp Change-Id: Iae3f3c00d46c903e2fa6c1dd49876839362f8001
| | * QDeclarativePositionSource::{supported|preferred}PositioningMethods() always ↵Jim Ehrismann2014-01-171-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | return AllPositioningMethods Also added unit test for preferredPositioningMethods() Change-Id: I28c1d5ce66987d3799d1d1cc97469112dd055a45 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
| | * Attempt to fix flaky QNemaPositionInfoSource_Simulation test on WindowsAlex Blasche2014-01-151-5/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The failure was discovered by https://codereview.qt-project.org/#change,75481 We increase the timeout for the local tcp connection as the likely reason is an overworked CI system. In addition we add more verbose output to easy the failure detection in case this happens again. Change-Id: I44ee52fcb957dcaa5aca4a6932221a34ce3f2af7 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* | | Remove offset attribute from place search requests.Aaron McCarthy2014-01-205-17/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | Not all service providers support arbitrary search offsets. The offset attribute has been removed, instead service providers can supply a previous and next search query in the form of a QPlaceSearchRequest. Change-Id: If68e969b06f909f3fa62718656cbef70d1bf84a6 Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* | | Fix Nokia place recommendation search parsing.Aaron McCarthy2014-01-201-15/+18
|/ / | | | | | | | | | | | | | | Place recommendations are no longer wrapped in a "results" object like other search requests. Change-Id: Idef11bf08818e07192657ffbadca0e0d610b6137 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Fix killing timer in different thread.Aaron McCarthy2014-01-171-13/+12
| | | | | | | | | | | | | | | | It was possible for another thread to attempt to stop the timer used by the tile fetcher. Change-Id: Ic44cf416bc7e6c987c4b5c9914a1c7d911dbbea5 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Fix tryCompare call with 2 parameters.Aaron McCarthy2014-01-161-1/+1
| | | | | | | | | | Change-Id: I2a10bd93bfef53af567777c85d794f07621d179d Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Fix coordinate animation test.Aaron McCarthy2014-01-161-2/+14
| | | | | | | | | | | | | | | | | | | | The Map was starting at coordinate 0,0, which the test was not expecting. Fixed by disabling animation when setting the starting coordinate. Task-number: QTBUG-31797 Change-Id: I5cadb28ad667d321b2c3e6440e0698e0ad59ed8e Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-01-1011-64/+62
|\ \ | |/ | | | | Change-Id: I7f649542227dcdeb062b0b8368a301334fa9969b
| * Stop skipping declarative_core tests.Aaron McCarthy2014-01-105-8/+29
| | | | | | | | | | | | | | | | These test cases were failing due to regressions in QML and have since been fixed. See QTBUG-33542, QTBUG-33546 and QTBUG-33561. Change-Id: Id86e9a8baa29eea851bda27cb668a6ce586c5f25 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
| * Fix declarative_core unit testAlex Blasche2014-01-109-68/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | There are still some bugs caused by V4 but more dedicated bugs but it is more important to get the current unit test running . We rather skip the problematic cases. A lot of warnings have been fixed as well. Task-number: QTBUG-31798 Change-Id: I1fccf26db5c47563baeaf6c2d6366d3c10aee824 Reviewed-by: Alex Blasche <alexander.blasche@digia.com> Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
| * Revert "Don't require applications to declare metatypes."Aaron McCarthy2013-12-107-0/+8
| | | | | | | | | | | | | | | | | | This reverts commit 5679a86968a6a26f8427b9c979f89f6ea5198d2f Change was source incompatible. Change-Id: Ied25ca3503a41e498a5c9b710e7a0dd3787bbe89 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
| * Don't require applications to declare metatypes.Aaron McCarthy2013-12-107-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | These metatypes need to be declared for common usage of the positioning API. Declare them in the library header files so that applications are not forced to do so. [ChangeLog][QtPositioning][General] Applications no longer need to register common Qt Positioning data types with the metatype system. Change-Id: I1d28ec8e33d20efc748cb6a0a2ad302e2061853f Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Use QVariantMap instead of QMap<QString, QVariant>.Aaron McCarthy2014-01-0818-27/+28
| | | | | | | | | | | | | | | | It is shorter, easier to read, easier to type and it doesn't affect the ABI. Change-Id: Ic4d8a371d00b434ac84382dd75d8d82a963089cb Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Enhance measurement system support in routing manager.Aaron McCarthy2014-01-071-7/+11
| | | | | | | | | | | | | | | | | | | | | | | | It is useful to be able to set the measurement system independently of the locale used by the routing manager. Add accessor functions for the measurement system to the routing manager classes. Locale and measurement system properties are also added to the RouteModel QML type. Change-Id: I8ee9fbdb5ab94615fef7019914b0f104aebfa9c8 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Support position accuracy in QNmeaPositionInfoSource.Aaron McCarthy2013-12-114-5/+64
| | | | | | | | | | | | | | | | | | | | | | | | Extract the HDOP and VDOP from the NMEA stream and calculate the twice the distance root mean square (2DRMS) error based on the user provided User equivalent range error value. [ChangeLog][QtPositioning][QNmeaPositionInfoSource] Added support for reporting position accuracy. Change-Id: I59e5f8c32070fa96ae4d0bd02a18f38663920e05 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Merge branch 'stable' into devAlex Blasche2013-11-114-4/+4
|\ \ | |/ | | | | Change-Id: Ia0af08e46e39b783ffa0773bbc43a9a5a78c28bc
| * Add NoError to the various Positioning Source classes.Alex Blasche2013-10-304-4/+4
| | | | | | | | | | | | | | This became apparent while implementing the BB10 and Android backends. Change-Id: I54e2c0fce63021b9fad0c544777792aed726608b Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* | Upgraded Nokia Route API from 6.2 to 7.2Erik Mattsson2013-11-113-809/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since the 7.2 API supports many more lanugages(23 compared to 4) and is the only version that supports China it was necessary to upgrade the nokia route plugin to 7.2. The major change is that 7.2 does not support multiple mode parameters which 6.2 did. Now if the user selects multiple route optimizations multiple requests will be made, one for each optimization. Nokia has also reduced the amount of different route modes, only fastest and shortest are supported now. In the response part noting has changed, so no parsing fixes were necessary. Task-number: QTBUG-24808 Change-Id: I256079f9a1e91e11c961849c95b95b712021ace0 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Always use double point precision for geo lookups internallyErik Mattsson2013-11-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is to remedy rounding errors on ARM devices where qreal is defined as a float instead of double. The main change is to replace QPointF with QDoubleVector2D when using screenPositionToCoordinate and coordinateToScreenPosition. In many cases the QDoubleVector2D is converted to QPointF when the increased precision is not used. This because many of the surounding classes uses qreal so the precsision would be lost anyway. These classes include QVectorPath, QPainterPath and QQuickItem. The most important change is in polyline and polygon map item in the updateSourcePoints methods. Using floating point precision here resulted in many precision errors that caused for example route lines to be chopped of as the method erroneously thought it needed to wrap to the other side of the datum line. The external uses of the coordinate lookup functions in declarative geo map has been left untouched so they still use QPointF for compatibility reasons. Not sure how the process goes when updating externally visible parts of the API Change-Id: I01ed67a0563cfb5c4ff2db6395b7a62eaa8e4a19 Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* | Fixed broken test cases with incomplete test plugin configurationAnders Gunnarsson2013-11-053-2/+3
| | | | | | | | | | | | | | | | The test plugin is experimental and requires allowExperimental == true to be used Change-Id: Id27d4b2a4a9597fc42a725435cac49b898010e4a Reviewed-by: Aaron McCarthy <mccarthy.aaron@gmail.com>
* | Enabled setting max/min zoom level in declarative mapErik Mattsson2013-10-241-0/+39
| | | | | | | | | | | | | | | | | | Created setters for max & min zoom level qproperty in declarative geo map. The new max/min values are set in the gesture area so the camera data values set by the plugin are still intact. Change-Id: I502159c1842238f41c2d598d2fb82c761af9535b Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Merge branch 'stable' into devAlex Blasche2013-10-2217-18/+19
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/imports/location/qdeclarativegeomap.cpp src/imports/location/qdeclarativegeoroute.cpp src/imports/location/qdeclarativegeoroutemodel.cpp src/imports/location/qdeclarativegeoroutesegment.cpp src/imports/location/qdeclarativepolygonmapitem.cpp src/imports/location/qdeclarativepolylinemapitem.cpp src/imports/positioning/positioning.cpp Change-Id: Ieaa5f567d2144d0267e7eef5bd75bde7e0079fbe
| * Update position when switching position sources.Aaron McCarthy2013-10-181-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The declarative position source only updates its position when an update arrives. The position property is now updated when: At construction time the position source may have a last known position available. When switching position sources, the position is updated to the last known position of the new source or invalidated in the case that no position source is selected. Change-Id: Ib67407f252f2e60d8fd4e32179847f465c1aaf94 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
| * Add proper version to QtPositioning and its QML API.Alex Blasche2013-10-1417-18/+18
| | | | | | | | | | | | | | | | | | The QML API remains available under 5.0 though. Change-Id: I037b82e5b12825db610e8458d6c82122ecde4f44 Reviewed-by: Erik Mattsson <erik.mattsson@appello.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Added qml function to fit map to geo shapeErik Mattsson2013-10-151-0/+61
| | | | | | | | | | | | | | | | | | | | | | Added a qml invokable function in the map object to fit the viewport to a geo shape. It's heavily influenced from fitViewportToMapItems. Also added some basic ui tests. Added handlig for the case with an empty shape Change-Id: Iecad849f2c1b6d9a54eab90e26435b31a138886c Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Make geo coordinates animatable in QML.Albin Olsson2013-10-1113-89/+172
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Interpolation logic in AnimatableCoordinate has been moved around so that QGeoCoordinates can be animated directly by QPropertyAnimation. A new QML type has been added, 'CoordinateAnimation', for animating coordinates in QML. This type follows the pattern of 'ColorAnimation' and other specializations of 'PropertyAnimation'. QDoubleVector2D, QDoubleVector3D and QGeoProjection has been moved to QtPositioning Testcase for CoordinateAnimation has been added to declarative_ui. AnimatableCoordinate and QGeoCoordinateInterpolator are redundant and have been removed. Change-Id: I0809da566e1800274384f9c5337df65623d1e61a Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
* | Added possibility to create a georectangle from a list of coordinatesErik Mattsson2013-10-076-1/+247
|/ | | | | | | | | | It will create the smallest possible rectangle that contains all of the coordinates. This is accessible from qml using the locationsingleton. The plan is to include the ability to fit the view-port of the map to a georectangle. Change-Id: I616ac8ef169f697e53a3d9ebcf114f4f2cde8298 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>