summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Fix crash in tst_qaccessibility.Friedemann Kleint2013-01-151-1/+1
| | | | | | | | Release the table item below the table test instead of releasing the text item twice. Change-Id: I74d283d50a39b9a4570b73a8297ed3dbb2de2271 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Change all shmget calls to user-only memoryThiago Macieira2013-01-151-1/+1
| | | | | | | | Drop the read and write permissions for group and other users in the system. Change-Id: I8fc753f09126651af3fb82df3049050f0b14e876 Reviewed-by: Richard J. Moore <rich@kde.org>
* test: Add bic data for linux-gcc-ia32Sergio Ahumada2013-01-088-0/+59020
| | | | | | Task-number: QTQAINFRA-321 Change-Id: I990f0c525fbd0b0b3818b0f7d86ed99438821baa Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix warnings about not being able to set Window geometry on Windows.Friedemann Kleint2013-01-0817-5/+171
| | | | | | | | | | Fully decorated windows cannot be smaller than 160x30 (Large fonts). Enlarge Windows or remove Window frame to get rid of decorations. Task-number: QTBUG-28611 Change-Id: Idb6ee94fb8d0760d5f97042b3084557f11e9fdf9 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Add auto test for HTTP cache fix for QTBUG-28035.Michael Brüning2013-01-081-0/+125
| | | | | | | | | Adds an auto test that verifies that the replies to POST and PUT requests are not cached even though they contain a max-age header and that subsequent GET requests are reloaded from the server. Change-Id: I188ae1200cb5551e164722c0f479719be8d11bfb Reviewed-by: Peter Hartmann <phartmann@rim.com>
* Add bic data for tst_bicSergio Ahumada2013-01-069-7/+59027
| | | | | | | | | - Add initial set of amd64 data - Add QtWidgets to global.cfg Task-number: QTQAINFRA-321 Change-Id: I9bffaa00ac01976546629988ac69965383eb2efd Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update qlocale autotestMehdi Fekari2013-01-061-0/+50
| | | | | | | | | | | Add additional tests for the updates in the Qt4.8 qlocale data (CLDRv2.0) already existing in Qt5 locale data (CLDRv22.1): - The NumberingSystem for some Indic and Slovak locales. - The Month/Day name in Irish/Gaelic locale. - The AM/PM Text in Turkish locale. Change-Id: Iaea4f13ec79f94ab937b97f8ae60eb8d8f217c4b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Tests: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-069-16/+0
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: Ifd116dee32a450ff89a9a1011e26b434765d6e95 Reviewed-by: David Faure <david.faure@kdab.com>
* Widgets: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-0438-91/+1
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: Ibe8e2ec867afb4051a3c7eef806d9cd86945928b Reviewed-by: David Faure <david.faure@kdab.com>
* Gui: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-0417-50/+0
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: I95b8b4b674e85b2b3c374931f6231d60f35be984 Reviewed-by: David Faure <david.faure@kdab.com>
* Core: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-0426-61/+0
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: I54523eb854619917123d8816d3cd6c3a1f5b4c55 Reviewed-by: David Faure <david.faure@kdab.com>
* Don't increase the reference count if dynamic_cast failedThiago Macieira2013-01-044-0/+174
| | | | | | | | | | | | | If the dynamic_cast failed in QSharedPointer::dynamicCast or qSharedPointerDynamicCast, we should avoid creating the QSharedPointer that shares the weak and strong reference counts. In Qt 5, this does not imply a leak since the original pointer is stored internally for deletion. In Qt 4 it implies a leak under certain circumstances, which this change fixes. Task-number: QTBUG-28924 Change-Id: Id2de140de4cf676461e14b201ad250c53666b79d Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* SSL certificates: blacklist mis-issued Turktrust certificatesPeter Hartmann2013-01-042-0/+55
| | | | | | | | | | | | Those certificates have erroneously set the CA attribute to true, meaning everybody in possesion of their keys can issue certificates on their own. Task-number: QTBUG-28937 Change-Id: Iff351e590ad3e6ab802e6fa1d65a9a9a9f7683de Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Make textEditTest pass on Windows 8Jan Arve Saether2013-01-041-4/+19
| | | | | | | We make it pass by relaxing the comparison of the characterRect.... Change-Id: I900e0601d9e1e568c12a3952cf42657743345013 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix autotest of textEditTest to use currentFont() instead of font()Jan Arve Saether2013-01-041-3/+3
| | | | | Change-Id: I5c9b2ad494a7daf9b07804f77c4692d49e774261 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* DBus: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-045-48/+0
| | | | | | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. In some cases, the type is required to be registered with the typedef name, so those Q_DECLARE_METATYPE uses remain for now. In a future patch we can also remove those and the typedefs themselves. Change-Id: I5721955c86f566ae09024203954840f817bd3088 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Fix QGuiApplication::keyboardModifiers() and QGuiApplication::mouseButtons()Jon Severinsson2013-01-041-0/+26
| | | | | | | | | | | | | | | | | Previous commit b2363a935c8dac fixed keyboardModifiers() after QPA event processing, but broke QTestLib, which expects spontaneous input events sent to qApp->notify() to update keyboardModifiers() and mouseButtons(). The commit also did not fix mouseButtons() after QPA event processing, and missed keyboardModifiers() after QPA Tablet event processing. This commit fixes all these shortcommings in b2363a935c8dac. Includes test case by David Faure <faure@kde.org> Task-Number: QTBUG-26887 Change-Id: I8518b06c4ce86ea7b35120e3353a45ea2a81d356 Reviewed-by: David Faure (KDE) <faure@kde.org> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Cleanup verifyHierarchy. Remove dead code and add indexOfChild testJan Arve Saether2013-01-031-5/+3
| | | | | Change-Id: I4f423cf2f08b657329b7fb5e225e7b8b3f17e4af Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Benchmarks: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-038-15/+0
| | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: Iba4b7f8ff7a1c7974d144b955cbf064e43b36ec7 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Network: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-034-11/+0
| | | | | | | | | These types are either built-in or 'automatically declared' and so don't need to be explicitly declared as metatypes. Change-Id: Ifdce72af844901665c4ebab11507216ba5f00fc1 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Don't read from deleted member variablePeter Kümmel2013-01-031-3/+9
| | | | | | | | QNetworkProxy::setApplicationProxy deletes factory set by QNetworkProxyFactory::setApplicationProxyFactory. Change-Id: Iaafd62d1cdb2045d69c7359cacc513056216826c Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Fix possible crash in QTextDocumentEskil Abrahamsen Blomfeldt2013-01-031-0/+25
| | | | | | | | | | | | | | | | With trailing spaces in some cases, we would not get the "no justification at end of paragraph" special case, and continue in the code, getting the unexpected case where line_length becomes < 0 which would lead to memory corruption because we were writing outside our buffers. I added an assert to catch this type of bug earlier, and I added the trailing spaces to the test for the end of the paragraph. The test case added is one example which would crash. Task-number: QTBUG-27354 Change-Id: Id720a6fa55dbc709ce04dd5321e55687bf960d75 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Remove metatype registration of built-in types.Stephen Kelly2013-01-0322-26/+0
| | | | | | | | As they are built-in, they are effectively registered at compile-time already. Change-Id: I7ae6ba16088eab5d19213fa7b07c2a7760988a86 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* test: Change trolltech.com:443 to qt-project.org:443Sergio Ahumada2013-01-031-1/+1
| | | | | | | | trolltech.com seems to be shut down already Change-Id: Ic90ce01aeb51b6f154b9bbf4762c365a398c9e3d Reviewed-by: Simo Fält <simo.falt@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Speed up and fix QByteArray::setNum()hjk2012-12-301-1/+18
| | | | | | | | | | | | Going through QLocale and QString is not really needed. This also makes the result of the conversion of negative numbers in bases other than 10 independent of the architecture and implements the documented behavior of treating them as unsigned types. Change-Id: Ibc231dc5241deb5cbadd9796484a8b5f79c29410 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Add test for QByteArray::setNumhjk2012-12-281-0/+27
| | | | | | Change-Id: I66f3954433bf50fb23fdaeef804838d993e965b5 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix QMutex::tryLock with negative valuesThiago Macieira2012-12-231-0/+51
| | | | | | | | | | | | The Linux futex implementation had a Q_ASSERT for positive values, but the documentation says that negative values should be interpreted as infinite (equal to lock()). Test that too. Change-Id: I2f96a502d672732781e88e49797756ca9a809121 Reviewed-by: David Faure (KDE) <faure@kde.org> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QUrl::fromUserInput: fix for urls without a host.David Faure2012-12-231-0/+4
| | | | | | | | | | QUrl::fromUserInput("http://") was invalid, which doesn't make sense since QUrl("http://") is valid. Same for "smb:" which is actually even more a valid URL from a user's point of view. Change-Id: I371ac393d61b49499edf5adbbc2a90b426fe9e5d Reviewed-by: Marco Martin <mart@kde.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix QSqlQuery test in relation to PSQL supportAndy Shaw2012-12-222-14/+28
| | | | | | | | | Some things needed to be corrected for testing with PSQL, this was checked against the the PostgreSQL documentation to confirm that the exepected behaviour is correct. Change-Id: I45a6b343e9eb920fcae2a62910ecc956abcac0f0 Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Make sure that the strict parser is also operating on setXxxThiago Macieira2012-12-211-0/+78
| | | | | | | | | | | These cases weren't handled before. The validateComponent function is copied from QUrlPrivate::parse, with the added modification that it now needs to check the gen-delims for the userinfo. Change-Id: I055167b977199fa86b56a3a7259a7445585129c6 Reviewed-by: David Faure (KDE) <faure@kde.org>
* add and use qtHaveModule() functionOswald Buddenhagen2012-12-2142-47/+47
| | | | | | | | | | | this is much more elegant than the so far propagated !isEmpty(QT.foo.name). also replace feature-specific tests (no-gui and no-widgets) and the obsolete contains(QT_CONFIG, foo) syntax. Change-Id: Ia4b3c8febcabf9eeca67b1f9173a523820b1038b Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Tasuku Suzuki <stasuku@gmail.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* Fix some typosSergio Ahumada2012-12-213-4/+4
| | | | | Change-Id: I4e8d9bd8ea66ec810e4f1fbfd8ddbf25c4b3d980 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* Add a manual test for QFile.Friedemann Kleint2012-12-213-0/+149
| | | | | | | | | Add a command line program allowing to test rename, copy, etc. Task-number: QTBUG-28246 Change-Id: Ie9667f03b65a874475700ec9ecd91ca2ed32ed97 Reviewed-by: David Faure (KDE) <faure@kde.org>
* Tests: stabilize tst_QAbstractScrollArea::setScrollBars2()J-P Nurmi2012-12-201-8/+8
| | | | | | | | | | | | Use QWidget::isVisibleTo(parent) instead of isVisible(), just like QAbstractScrollArea::replaceScrollBar() does. This removes the need of using QCoreApplication::processEvents() to deliver the actual hide event just for testing if the scrollbar was requested to be hidden as it should. Change-Id: Ie9a816e7b871d280a4b3d9d76adb10601915bd56 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* tst_QDBusXmlParser: more reliable solution for setting the seedDavid Faure2012-12-201-2/+8
| | | | | | | | | As recommended by Giuseppe, don't rely on the env var, but use the internal but exported seed atomic int. This way, the compiler will detect breakages, rather than runtime. Change-Id: Iec2bc88c53532d3463d2dc5c73631fc9bc34747b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fixes: out of bounds memory access in QImage autotestaavit2012-12-201-2/+2
| | | | | | | | | | | | | A pointer to the data of one qimage is used, with an offset, in a copy. In the mono case, that could lead to overflow: the last row would of the copy would stretch 1 byte beyond the end of the allocated area. Fix by reducing the height of the copy, so that it keeps within the allocated memory. Task-number: QTBUG-28322 Change-Id: I09abfc83f738f8af000fc50f8c94f63dba3a6cfe Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* QUrl auto tests: make sure setAuthority is consistent with setHostPeter Hartmann2012-12-201-0/+24
| | | | | | | ... with respect to empty and null strings. Change-Id: Ic107d5bcc8b659497a567b75a7244caceba5a715 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Disable the JSC portion of the test unless we have a system PCREThiago Macieira2012-12-201-1/+1
| | | | | | | | CONFIG += pcre is enabled if we're using the Qt PCRE, which isn't compiled for 8-bit. If it isn't set, then we have a system PCRE. Change-Id: I29d043b9d3f4d3223dcbb41eadc9f859e710eb88 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* QUrl auto tests: ensure toEncoded() and toString() match wrt. empty authPeter Hartmann2012-12-201-0/+6
| | | | | | | Task-number: QTBUG-8701 Change-Id: I55780a910a0d0996488475f5ce49a240f6223df0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* tst_qaccessibility: Fix warnings about window geometry on Windows.Friedemann Kleint2012-12-191-0/+22
| | | | | | | | | Make windows frameless so that size constraints for decorated windows do not interfere. Task-number: QTBUG-28696 Change-Id: Ic4410d8a6e8166bdfe013ed2362173f8e02d4b29 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Change ftp.qt.nokia.com -> ftp.qt-project.orgSergio Ahumada2012-12-182-23/+23
| | | | | | Task-number: QTBUG-28156 Change-Id: I0060144f0336791933205355b125251ccba73b3e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QMdiArea: Increase minimum size for Windows 8/Large fonts.Friedemann Kleint2012-12-181-2/+2
| | | | | | | Task-number: QTBUG-28611 Change-Id: I115a5fa6726ac99c2bbff4ec65d3f8856b2530df Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Fix QStyle-test for Windows Aero / 8.Friedemann Kleint2012-12-181-3/+29
| | | | | | | | | | | | Increase tolerance on Windows for the Aero style. Set small top level widgets frameless to avoid warnings about minimum size of decorated windows on Windows. Task-number: QTBUG-28611 Change-Id: Ia4aec0cf0763da9955577054cb8cf81337fac134 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* tst_qstyle: Fix compiler warning about unused variables.Friedemann Kleint2012-12-171-2/+2
| | | | | Change-Id: Ida6a45be577cc1e21a2ba2b45f57b1e96c944fb2 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Use frameless widgets in tst_qgridlayout.Friedemann Kleint2012-12-171-1/+29
| | | | | | | | Avoid failures caused by minimum window widths on Windows Areo/8. Task-number: QTBUG-28611 Change-Id: I9affcce84ab804a45fa1a12fb93ad0136e6ae877 Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
* Delete the QSlotObject when disconnect()ingGiuseppe D'Angelo2012-12-171-8/+39
| | | | | | | | | | | | | | | When disconnect()ing through a QMetaObject::Connection, if the QObjectPrivate::Connection contains a slot object, deref it, so that it will be destroyed before the next run of cleanConnectionList. Previously, a copy of the functor passed to connect() was kept until QObjectPrivate::cleanConnectionLists was called (by adding a new signal, or the sender was destroyed), even after a successful call to disconnect(). That is, we were keeping that copy allocated without any good reason. Change-Id: Ie6074ea797df1611cb995dec07c5b5a742360833 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Reset the QMetaObject::Connection dptr when disconnect()ingGiuseppe D'Angelo2012-12-171-0/+56
| | | | | | | | | | | | The QObjectPrivate::Connection refcount was not decreased when disconnect()ing, therefore it was kept alive by the owning QMetaObject::Connection object. This removes a leak in case the QMetaObject::Connection survives the sender object, after a successful disconnect(). Change-Id: Ie2ea59b269a0e589ae23c1457df7533be77c0797 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Remove useless QVERIFY(true)Giuseppe D'Angelo2012-12-171-2/+0
| | | | | | | | More QVERIFY()s were added in the meanwhile to the test function, so we can drop this one. Change-Id: If6f137f45ba606b61d6a7004556a667ed316b61f Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* clean up example project files, mostly wrt QT+=widgetsOswald Buddenhagen2012-12-171-1/+1
| | | | | | | | | move QT+=widgets (and printsupport) statements before the install statements, and de-duplicate some cases. also move some TARGET assignments to a more conventional place. Change-Id: I6140d8611680f66c24490e5894e4eb90cae95635 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* remove obsolete DEPENDPATH assignmentsOswald Buddenhagen2012-12-175-5/+0
| | | | | | | | qmake now add CONFIG+=depend_includepath by default, making manual DEPENDPATH setup unnecessary. Change-Id: Ie57cf05c369e21b5b9e099b6ce9be4f75da1508f Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>