summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Respect the size hint signal for the column and row delegatesAndy Shaw2014-12-031-2/+42
| | | | | | | | | | | | | | The sizeHintChanged() signal from the column and row delegates need to be connected to the doItemsLayout() slot so that the view is updated when the size hint changes. Additionally doDelayedItemsLayout() is called to ensure that this is up-to-date as the size hints may have changed when the new delegate was set on the row or column. Change-Id: I458293f05ce9ef40a03bdbcab1a6e7a10f648c89 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com> Reviewed-by: Kevin Puetz <PuetzKevinA@JohnDeere.com>
* QLayout: Observe contents margin when positioning the menu bar.Friedemann Kleint2014-12-021-0/+3
| | | | | | Task-number: QTBUG-38152 Change-Id: I53ea6bce33057251265a7eca1651aeabca314ba9 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* QMainWindow: Observe left contents margin when positioning status bar.Friedemann Kleint2014-12-021-0/+33
| | | | | | Task-number: QTBUG-38152 Change-Id: I4c762a113dbfe47472d1087aa34c0e327083ee16 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* tst_qsortfilterproxymodel: remove unused member varDavid Faure2014-11-281-2/+1
| | | | | | | (clang warning) Change-Id: Id751443e03be4f2bd1721cbe9d9a898d9619b29b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.4.0' into 5.4Frederik Gladhorn2014-11-2711-69/+71
|\ | | | | | | | | | | | | | | | | | | Conflicts: dist/changes-5.4.0 7231e1fbe24102f2a93b34dfa70e3dca884440d2 went into 5.4 instead of the 5.4.0 branch, thus the conflict. Change-Id: I70b8597ab52506490dcaf700427183950d42cbd1
| * Adjust DBMSType to DbmsType to follow conventionsAlejandro Exojo2014-11-268-67/+67
| | | | | | | | | | | | | | | | | | The enum was made public in f84b00c6d26eb7a3a6802210d2a8b12ddbf815aa, but this makes it follow the convention to camel case acronyms too before it's too late to change it. Change-Id: Ibb81e9221cb73fe0502d0a26f2d73512dd142f08 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Blacklist one tst_qsslsocket testTony Sarajärvi2014-11-261-0/+2
| | | | | | | | | | | | Task-number: QTBUG-29941 Change-Id: Ieb3418a2d6d88ebd399964b5df20d9fe4d6ca37b Reviewed-by: Simo Fält <simo.falt@digia.com>
| * Use camel case in PKCS#12 functionAlejandro Exojo2014-11-241-1/+1
| | | | | | | | | | | | | | | | | | This makes it follow the coding style, which says to camel case acronyms too, and makes it consistent with the rest of the class. Change-Id: I4a1b21de1815530e476fc5aa8a0d41c724fc8021 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: hjk <hjk121@nokiamail.com>
| * Blacklist one test function in tst_QNetworkReplyTony Sarajärvi2014-11-211-0/+3
| | | | | | | | | | | | | | | | | | | | This patch is cherry-picked from c38f1f19b87d20f79394bca151268fc3cdcdd189 and d29d727d720fa4ac7ba046b6bfb96707586de7d3 Task-number: QTBUG-32435 Change-Id: I6dbbb668b96737a5791bc688949a00bc09f1357f Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
| * Mark QSocks5SocketEngine tests blacklistedTony Sarajärvi2014-11-211-0/+4
| | | | | | | | | | | | | | | | | | | | This patch is cherry-picked from 63ae74f36533d92c5b38df1eb2a7fcf4c586bf11 and 07f234d2a8283081aabdd1465f09b04a26bec1a3 Task-number: QTBUG-42528 Change-Id: I5f86679e62a4be48ce25afa5a4987a2b6678a357 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
| * Fix the %{time} printing to *not* default to the process's timeThiago Macieira2014-11-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | The default should be the actual time of day. Showing the process's time is the optional case. In the future, we'll provide a way to showing the monotonic reference time ("boot") and we should improve the detection of actual application runtime. Change-Id: I41936d77ab9fad2073dc0ce1c97cabe57ec39f16 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Diaglib: Fix typo in .pri file.Friedemann Kleint2014-11-271-1/+1
| | | | | | | | | | | | | | Fixes compilation with Qt 4. Change-Id: I66781089cd4c07a33f8136706e3211a21f41039f Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | QLineEdit: take text margins into account in minimumSizeHint().David Faure2014-11-271-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | sizeHint() did it exactly like this, but minimumSizeHint() didn't, which made it too small. Didn't affect the actual size in most cases since the vertical size policy is fixed, so sizeHint() is called instead. But when writing a subclass, if one re-implements sizeHint() by calling the QLineEdit's minimumSizeHint(), it would then be wrong, when text margins are used. Change-Id: I29ae8dcab00842b3b5ca534cdb250efc0b496f45 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | XCB: send leave event on grabJørgen Lind2014-11-261-46/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When a popup is opened it grabs the input, but the leave event to the other windows needs to be sent. Remove the popupEnterLeave test as it did not test any code. The Popup never gets any enter or leave events so it will succeed always succeed Task-number: QTBUG-36862 Change-Id: I625c616eeb74b5168af7b751485e2a9a53b76cd3 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Improve diaglib.Friedemann Kleint2014-11-253-6/+57
| | | | | | | | | | | | | | | | | | - Fix prototype for glinfo() for Qt 4 - Add more event types and object type flags to event filter. Change-Id: Ia4160b40486d054e860a339e7b5c9c28695330ae Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* | QAbstractProxyModel: fix canDropMimeData/dropMimeData implementationsDavid Faure2014-11-241-0/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The code in 4696e9dbaa4 was incorrect. It is perfectly valid to call these methods with row=-1 column=1 parent=some_index, this is exactly what happens in QListView and QTableView. Child row/column is only for trees. Move the coordinate mapping from QSortFilterProxyModel into a new mapDropCoordinatesToSource internal method, used by QAbstractProxyModel. Task-number: QTBUG-39549 Change-Id: I3312210473d84b639cbe4c01f70ea36437db3e91 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Stephen Kelly <steveire@gmail.com>
* | tst_qtableview: fix virtual-override clang warningDavid Faure2014-11-241-2/+2
| | | | | | | | | | Change-Id: I40391890c988ce15d8fa65898976bf0fdc446992 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | Disable the tests that verify that the available space shrunkThiago Macieira2014-11-221-0/+10
| | | | | | | | | | | | | | | | | | Somehow, it doesn't shrink with btrfs, even if you write 1 MB of non- null data. This does not seem to be a bug in QStorageInfo. strace confirms that there is a second statvfs call happening. Change-Id: I9ed99d27d25e191916278e6b8faeae132469fc63 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* | Fix tst_QEventLoop::processEventsExcludeSocket testJan-Marek Glogowski2014-11-211-9/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The testcase always returns the expected result, independently of the QEventLoop::ExcludeSocketNotifiers flag to processEvents. In Qt4 the same test uses an intermediate QEventLoop and already runs it before the QEventLoop::ExcludeSocketNotifiers: QEventLoop loop; // allow the TCP/IP stack time to loopback the data, // so our socket is ready to read QTimer::singleShot(200, &loop, SLOT(quit())); loop.exec(QEventLoop::ExcludeSocketNotifiers); This fixes and improves the test by connecting, processing and checking the bytesWritten signal for the pending connection socket. Change-Id: I1b1d2b7b83910c87ba3fe48e29ac9fd585ac62ad Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.4.0' into 5.4Frederik Gladhorn2014-11-213-17/+7
|\| | | | | | | Change-Id: I95f235a66ce2e9b1fa435c0f911c6f7e811755f0
| * Make it possible to disable font embeddingEskil Abrahamsen Blomfeldt2014-11-151-15/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When font embedding is explicitly disabled, fall back to painter paths as we would if the font prohibits embedding. Note that this flag was never respected on any platform in any version of Qt, as far as I've been able to tell, because the handling of it in the X11 print engine was removed shortly after it was introduced in 2005. [ChangeLog][Printing] Disabling font embedding is now possible using the QPrinter::setFontEmbedding() function. Task-number: QTBUG-41943 Change-Id: Ice5e893f9893c5243310ae7892bec7497dd55c4a Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
| * Make QVersionNumber privateThiago Macieira2014-11-132-2/+2
| | | | | | | | | | | | | | | | | | | | We're not ready. [ChangeLog][EDITORIAL] Remove all mentions of QVersionNumber. Change-Id: I03ad95992982eb3177f982c1eeddb6a6bc29336c Reviewed-by: Keith Gardner <kreios4004@gmail.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* | Fix QAction::setFont crash on OSX, when font is unknown.David Faure2014-11-211-0/+10
| | | | | | | | | | | | | | | | | | | | customMenuFont was null, so objects was an empty array, and NSDictionary throws an exception when being called with arrays of different sizes. Task-number: QTBUG-42728 Change-Id: I8cdab449fd8c1d12b65c46dd5617a7f5e3e96c6e Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
* | Fix widget leak in tst_qmainwindow.Friedemann Kleint2014-11-201-0/+8
| | | | | | | | | | | | Task-number: QTBUG-38152 Change-Id: I4cf94a4a8977019dcfc099966643b5b036cc1021 Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
* | Observe QLocale::RejectGroupSeparator in QInt/DoubleValidator.Friedemann Kleint2014-11-201-9/+18
| | | | | | | | | | | | | | | | Pass it as additional boolean parameter to QLocaleData::validateChars(). Task-number: QTBUG-42522 Change-Id: I4b2367f4e2fdcbd17e343d215edad57e6687697a Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* | Fix QString::section() behavior on negative and out-of-range indexesAlex Trotsenko2014-11-201-0/+22
| | | | | | | | | | Change-Id: I3bff6ba73b15ee810bb11b2902d11244c3205b2a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Fix how qsocks5socketengine autotests are blacklistedTony Sarajärvi2014-11-201-0/+2
| | | | | | | | | | Change-Id: I6436491267b737fc00c33af7bd9491510c21b7c5 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* | fix how qnetworkreply autotests are blacklistedTony Sarajärvi2014-11-201-0/+2
| | | | | | | | | | Change-Id: Id5b0ec07504020f246e57d3ad57ffd5ce0be61ab Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* | Allow empty string as intermediate matchPaul Olav Tvete2014-11-201-0/+3
| | | | | | | | | | | | | | | | | | | | | | QRegularExpressionValidator and QRegularExpression disagree on what a partial match means. [ChangeLog][QtGui][QRegularExpressionValidator] Allow empty string as intermediate match Change-Id: Ia6c55beb54870b1be5c88b6ef3eceebc8ca3f86b Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | QSortFilterProxyModel: keep the sorting on unrelated changesGiuseppe D'Angelo2014-11-201-0/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Whenever the source model of a QSortFilterProxyModel changes, and the changes involve the sorted column, the implementation removes the changed rows from the mapping, sorts them, and inserts them back; in case of identical items, the rows are inserted at the end of the block of equal rows. The problem is that if the change doesn't actually happen on the roles that are used for sorting, then we shuffle the rows, terribly confusing the user. The typical case is a model with identical checkable rows: (un)checking one row will move it at the end. So, instead of trying to be smart with the removal/sort/insert sorted, simply resort everything under the changed parent index. Since the sorting used is stable, this keeps the items in the same positions. Task-number: QTBUG-1548 Change-Id: Id0e61bd49da53b0a3e8aefa6b6893ac41179dc6f Reviewed-by: David Faure <david.faure@kdab.com>
* | Enable tst_QGraphicsView on OSXJørgen Lind2014-11-192-1/+9
| | | | | | | | | | Change-Id: If1cec2ff90ff0a4bdcfdd0e21aa5c2118ce4e862 Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* | Enable tst_qfiledialog2 on OSXJørgen Lind2014-11-192-1/+2
| | | | | | | | | | | | Change-Id: I7147d326b0f5bb218f4dbc013ed82efb4c1e1440 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
* | Fix rubberband position for tabbed mdi windowsPaul Olav Tvete2014-11-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | Place the rubberband over the tabs instead of where the hidden subwindows happen to be. [ChangeLog][QtWidgets][QMdiArea] Fix rubberband position for tabbed mdi windows Task-number: QTBUG-42612 Change-Id: I41e81ab8b99ab9e0fa533fd4ed1b2a8141d19753 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | Fix invalid qmake syntaxPaul Olav Tvete2014-11-191-3/+5
| | | | | | | | | | | | | | | | Task-number: QTBUG-42549 Change-Id: I57ba3150e3a3b915faf0356d8a3f89801eb4963e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* | Add Windows-specific notation for WebDAV to QUrl.Friedemann Kleint2014-11-171-0/+9
| | | | | | | | | | | | | | | | | | | | | | Convert a Windows-specific WebDAV specification "//host@SSL/path" into URL's with scheme set to "webdavs" and back to local file (Windows only). Task-number: QTBUG-42346 Change-Id: I12663243848ea7b2d3f208743e837e9de14a93eb Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | QPanGestureRecognizer: Make the number of touch points a parameter.Friedemann Kleint2014-11-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Prepare for determining the suitable number of touch points from the device type. For now, 2 points are used as before, which can be overridden by setting the environment variable QT_PAN_TOUCHPOINTS. Add member variable to QPanGesturePrivate which is set on gesture creation and later used for comparison. Task-number: QTBUG-40461 Change-Id: I6d9e35ca752375bc6a54435482ca0925195b8142 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Blacklist one test function in tst_QNetworkReplyTony Sarajärvi2014-11-141-0/+1
| | | | | | | | | | | | Task-number: QTBUG-32435 Change-Id: I07b1888b33daa00864e1793c1d12b1dccf562664 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* | Add C++11 if available for QVariant autotestJørgen Lind2014-11-131-0/+1
| | | | | | | | | | | | | | | | | | gcc 4.9 has the __has_include feature which enables the TEST_FORWARD_LIST and includes the forward_list header. This in turn checks that the c++11 flags are enabled, or throws an error. Change-Id: I44aa58e47c2f9ba6f14cb5a68d24da4a76698e5f Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* | Add diaglib under manual tests.Friedemann Kleint2014-11-1313-0/+1104
| | | | | | | | | | | | | | | | | | | | | | Add a set of helper functions and classes providing functionality for dumping widget/window hierarchies and logging events. They can be used by including a .pri file for diagnosing bugs and comparing Qt 5 to Qt 4. Change-Id: I0206f8e57b02540cd80a3e9446c894023d442ddc Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Mark QSocks5SocketEngine tests blacklistedTony Sarajärvi2014-11-131-0/+2
| | | | | | | | | | | | Task-number: QTBUG-42528 Change-Id: I3ba17b9d0f604215e6be0ec7199b12bf009c8b55 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* | Fixed QtGui's GL paint engine getting out of sync when using QtOpenGLSamuel Rødal2014-11-111-0/+27
| | | | | | | | | | | | | | | | | | | | We need to reset the active_engine belonging to QOpenGLContext whenever we make the QtOpenGL paint engine active, to give the OpenGL paint engine in QtGui a chance to sync its state if we've used the QtOpenGL paint engine inbetween. Change-Id: I445ce2f99bfbacf55650c881c4fdf07f2ff85069 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* | Fix for current_fbo getting out of sync in QtOpenGLSamuel Rødal2014-11-111-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using QGLWidget in combination with QOpenGLFramebufferObject from QtGui, instead of QGLFramebufferObject from QtOpenGL, the current_fbo variable doesn't get updated when framebuffer object bindings change. To ensure that the QGLWidget correctly releases the currently bound framebuffer object when using a QPainter, we keep track of whether QOpenGLFramebufferObject has modified the current FBO binding, and if that's the case we need to read the OpenGL state directly instead of relying on a cached value. Change-Id: If7e0bd936e202cad07365b5ce641ee01d2251930 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* | tst_qitemdelegate: make the test more robustDavid Faure2014-11-111-3/+1
| | | | | | | | | | Change-Id: Ieb05d7a05d5d8f6f652a0351deba7208d0770dd6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
* | tst_QTimer::singleShotToFunctors: Allocate static event loop on heap.Friedemann Kleint2014-11-111-5/+14
|/ | | | | | | | | | | Fix warning: QEventLoop: Cannot be used without QApplication and occasional crashes on Windows. Task-number: QTBUG-26406 Change-Id: Ia8b2a4e3d375d1e43f0e66fe64a39af5f9cf4d60 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Dario Freddi <dario.freddi@ispirata.com>
* Define Q_CC_CLANG to be the version of upstream Clang that's in useTor Arne Vestbø2014-11-051-1/+1
| | | | | | | | | | | | We map the Apple Clang versions to upstream, so that we have one define to compare against. Fixes build break on iOS due to qbasicatomic.h not defining QT_BASIC_ATOMIC_HAS_CONSTRUCTORS on Apple Clang versions, which is needed after 1e9db9f5e18123f2e686c10b Change-Id: I17493c0187c20abc5d22e71944d62bfd16afbad2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix too many resizes and move events for native widgetsJørgen Lind2014-11-041-0/+101
| | | | | | | | | | | | | | | When the QWidgetWindow receives a resize or move event, it should check with the widget if its crect already has this geometry. if not then send the resize or move event Ideally events should be sent whenever the QWidgetWindow receives them. QTBUG-42383 is created for this problem Task-number: QTBUG-29937 Task-number: QTBUG-38768 Task-number: QTBUG-30744 Change-Id: I1e9a5d25de29a98885edece927ba14d7a763eb01 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Autotest: synchronize with the peer before emitting more signalsThiago Macieira2014-10-312-1/+38
| | | | | | | | | | | | | | | Several of the unit tests request that the peer emit more than one signal, but only handle one. The rest of the signals stay queued in the socket and will be delivered at the next test, causing it to fail often. This doesn't happen in the tests with the bus. There, we don't receive the extraneous signals due to AddMatch/ReceiveMatch on each signal individually and the synchronous nature of the emission (the signals have already been emitted by the next AddMatch and cannot match it). Task-number: QTBUG-42145 Change-Id: I743a0553074972042fca46b76db5d9e7b3209620 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Remove executable mode on qwidget_window.proJørgen Lind2014-10-311-0/+0
| | | | | Change-Id: Ibb522af33e8490719010af441cce712bdc7a71bf Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* Add manual test for touch events.Friedemann Kleint2014-10-303-0/+215
| | | | | | | | | Unlike qtouchevents, this provides a touch area which logs its events and devices. Task-number: QTBUG-40461 Change-Id: Iaaa3589dd692caf8c7078f5ed2ff1e8b2322a369 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* tst_qvariant: automate testing of forward_listMarc Mutz2014-10-291-6/+6
| | | | | | | ...using the SD-6 __has_include macro. Change-Id: I629e2ad1c8090aba9e86ab9febf6d09a504219f9 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>