summaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
* QGuiApplication: Add fontChanged signalKai Uwe Broulik2018-01-111-0/+26
| | | | | | | | | | | This removes the need to install an event filter on qApp just for this. A similar thing was done with setPalette to reduce the number of event filters in e.g. SystemPalette and Quick Controls. [ChangeLog][QtGui][QGuiApplication] Added fontChanged signal Change-Id: Ifa843aa42b91ac63ab17c3b064ac0e764aac77d3 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Blacklist tst_QNetworkInterface::localAddress(linklocal-ipv4) in ciLiang Qi2018-01-101-0/+4
| | | | | | | | To unblock qt5 5.10->dev merge. Task-number: QTBUG-65667 Change-Id: Iffd3648913efb52ad5be9dc5310a9f836fab3de1 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Enable brainpool curves in qsslkey testsAndré Klitzing2018-01-1013-3/+34
| | | | | | | Change-Id: Ibdc0a045e0b0469bfb4dc362e3bc3e6b7940d783 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* QAbstractItemModelTester: fix the autotestsGiuseppe D'Angelo2018-01-0916-710/+44
| | | | | | | | Move the modeltest autotest in the right place, and fix the other autotests that were using it to use the version now in QtTestLib. Change-Id: Ic6838945f616d580f357c872ce0956c341be3b16 Reviewed-by: David Faure <david.faure@kdab.com>
* QSsl* tests: Ensure trailing slash on directory pathMårten Nordheim2018-01-092-43/+47
| | | | | | | Then we don't need to add a leading slash. (minor clean-up) Change-Id: I86af224841009fda838e7cb89d47d324963328c9 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Revert "Adapt the QSsl* tests to use the resource system"Mårten Nordheim2018-01-099-319/+173
| | | | | | | | | | | | | This reverts commit e1600c1a73e0594f5fbea8f7341a9552d6ae3fbb. The commit missed the fact that TESTDATA exists. Which supports wildcards and then can automatically pick up new files when added (as long as they match a wildcard) and then you don't need to maintain a giant qrc file. Change-Id: Ie31fadb5ef6e8dfe6105f4f9764292f78cffb512 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Introduce QAbstractItemModel::checkIndex()Giuseppe D'Angelo2018-01-082-1/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When implementing a custom model there's the habit, in each and every function that takes a QModelIndex, to carefully checking the index passed by the caller. This index is checked for "legality" (*): does the index belong to this model, is the index pointing to an existing row and column, and so on. These checks are hand-rolled and, as such, slightly different and possibly incomplete (i.e. wrong) every time. What's worse, these checks are implemented via "ordinary" code (if statements). However, passing an illegal index to a QAIM function is a precondition violation, and as such does not (and must not) be checked in ordinary conditions, as it triggers undefined behavior. On the other hand, while debugging a custom model or a custom hierarchy of (proxy) models, having such checks in place can be a significant aid. Enter checkIndex(): a debugging helper for QAbstractItemModel and its subclasses. checkIndex() centralizes the checks for legality of a given index. User code is free to assert on it, or have some other fallback mechanism in case a check fails. (*) Using "legality" here instead of "validity" in order to avoid confusion between QModelIndex::isValid() and what checkIndex() really does. [ChangeLog][QtCore][QAbstractItemModel] Added QAbstractItemModel::checkIndex(), a debugging function for QAbstractItemModel subclasses. Change-Id: I1eea0586b1ac3ededdbfbf46759145022dc5ad86 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com> Reviewed-by: David Faure <david.faure@kdab.com>
* QStringBuilder: add support for QStringViewMarc Mutz2018-01-081-0/+14
| | | | | | | | | [ChangeLog][QtCore][QStringBuilder] Added support for QStringView. Change-Id: I5b6803397b107ef69d198a935b3ba4339ac95087 Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QStringBuilder: add support for char16_t{,*,[]}Marc Mutz2018-01-081-0/+41
| | | | | | | | | | [ChangeLog][QtCore][QStringBuilder] Added support for char16_t characters and strings. Change-Id: Iee727f07226f2a326ae0df28d44930336cd8f71e Reviewed-by: Milian Wolff <milian.wolff@kdab.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QPSQL: Add support for multiple result setsRobert Szefner2018-01-081-4/+48
| | | | | | | | | | | | | | | | This change adds support for multiple result sets in PostgreSQL. [Important Behavior Changes] The QPSQL driver now supports multiple result sets. Since QPSQL previously did not support multiple result sets, there may be some compatibility issues with the existing code that executed several queries as one and were expecting to get the results of the last one. In this case use QSqlQuery::nextResult() to move to the last result set. [ChangeLog][QtSql][QPSQL] Added support for multiple result sets Change-Id: I2bfc91f512c4dac83116f3aa42833839a6da084c Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Cocoa: Make AA_MacDontSwapCtrlMeta workAndy Shaw2018-01-082-4/+2
| | | | | | | Task-number: QTBUG-22775 Task-number: QTBUG-51293 Change-Id: If615426001a1ea482f854f49cbae33ca1c954e9a Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* QStringBuilder: clean up testMarc Mutz2018-01-071-36/+102
| | | | | | | | Add some macros to enable systematic testing of QStringBuilder expressions. Change-Id: I6b7dbcb4a4ca0d1aebdfe7cb9861af881c0cd346 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QMenuBar: Add overloads of addAction() using Qt 5 signals and slotsAnton Kudryavtsev2018-01-061-0/+38
| | | | | | | [ChangeLog][QtWidgets][QMenuBar] Add overloads of addAction() using Qt 5 signals and slots Change-Id: Ief21974213b80111f0ca87df490eb72dd6b9c9b9 Reviewed-by: Martin Smith <martin.smith@qt.io>
* QPSQL: Add support for forward-only queriesRobert Szefner2018-01-061-0/+209
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this change, it is possible to significantly reduce memory consumption of applications that fetch large result sets from databases. The implementation is based on the new functionality called "single-row mode" that was introduced in PostgreSQL version 9.2: https://www.postgresql.org/docs/9.2/static/libpq-async.html It also uses asynchronous commands PQsendQuery(), PQgetResult(): https://www.postgresql.org/docs/9.2/static/libpq-single-row-mode.html [ChangeLog][QtSql][QPSQL] Added support for forward-only queries (requires libpq version 9.2 or later) [Important Behavior Changes] The QPSQL driver now supports forward-only queries. To use this feature, you must build QPSQL plugin with PostreSQL client library version 9.2 or later. See the Qt SQL documentation for more information about QPSQL limitations of forward-only queries (sql-driver.html). [Important Behavior Changes] If you build the QPSQL plugin with PostgreSQL version 9.2 or later, then you must distribute your application with libpq version 9.2 or later. Otherwise, the QPSQL plugin will fail to load. Task-number: QTBUG-63714 Change-Id: I15db8c8fd664f2a1f719329f5d113511fa69010c Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QHeaderView: respect min/maximumSectionSize propertyChristian Ehrlicher2018-01-062-6/+96
| | | | | | | | | | | | | QHeaderView::resizeSection() did not check if the given section size is inside the min/max property bounds. Also on calling setMin/MaximumSectionSize() the current section sizes were not checked if they are inside the new given bounds. This is a small behavior change when a user is setting the section size via resizeSection() without respecting the min/maxSectionSizes. Task-number: QTBUG-64173 Change-Id: Ia9c9eebf058d60c776ab5f8f8336642013ec553f Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
* Add an option to scroll the QComboBox on macOS with the mouse wheelAndy Shaw2018-01-051-6/+6
| | | | | | | | | | | | | | | | | | Since there may be some applications that want to make their comboboxes scrollable or not with the mouse wheel then a style hint is added to make this toggable. It defaults to true for all platforms except macOS to keep it in line with existing behavior. [ChangeLog][QtWidgets][QStyle] Added SH_ComboBox_AllowWheelScrolling as a style hint to enable/disable the use of the mouse wheel in a QComboBox. This defaults to true in all styles except the macOS one so there is no change in existing behavior. Task-number: QTBUG-53094 Change-Id: I6eb61e1990bfc79e3b3ea82d7b91ee39096fa077 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Tests: Raise minimum supported MSVC version to 2015Friedemann Kleint2018-01-046-25/+6
| | | | | | | | Remove code for older versions and streamline #ifdefs. Task-number: QTBUG-51673 Change-Id: If456567691538b1a1f452111814c5f9eba401c43 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge remote-tracking branch 'origin/5.10' into devLiang Qi2018-01-0412-0/+100442
|\ | | | | | | Change-Id: I644cd82b0d952b7d139e0228bf5017f147db77e7
| * Add binary compatibility files for QtBase for 5.10Milla Pohjanheimo2018-01-0411-0/+100442
| | | | | | | | | | | | | | | | | | | | Files to test binary compatibility for 5.10 added. It looks like tst_bic (that runs the BC tests) is implemented so that it will start testing new content when e.g in case of 5.10 branching to 5.10.1 has happened. Change-Id: Ic97db0339cc2942c088962dda495eb42b96fe153 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Merge remote-tracking branch 'origin/5.9' into 5.10Liang Qi2018-01-041-0/+0
| |\ | | | | | | | | | Change-Id: I3fa5c9e216201bdf7da260c395f65d7fb95cba0b
| | * Fix source code file permissionsSimon Hausmann2018-01-021-0/+0
| | | | | | | | | | | | | | | | | | | | | | | | Fix permissions after commit ffc8409aa58c04c1dd140001976b55925ac959f6 - our source files are not executable. Change-Id: Idc5103704256b6f73857b645c323492beaabe879 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | QTreeWidget: fix visualItemRect()Christian Ehrlicher2018-01-031-0/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QTreeWidget::visualItemRect() returned an invalid QRect when a column was moved and then hidden (or the other way round). The reason was that the logical index returned by QHeaderView::logicalIndexAt() was again passed to QHeaderView::logicalIndex() to create the QModelIndexes needed for QTreeView::visualRect() Task-number: QTBUG-28733 Change-Id: I8676f21bcab8c05c2260b85d483902f18cbf3e24 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
* | | Update Text segmentation and line break data to Unicode 10.0Lars Knoll2018-01-034-3835/+5833
| | | | | | | | | | | | | | | | | | | | | | | | Also adjusted the text segmentation and line break algorithms so that they can handle the new data, and pass the test suite. Change-Id: Ib727fd80003e34e96458d7a681996de3fa3691e7 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Update QString::isRightToLeft() to take directional hints into accountLars Knoll2018-01-031-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure we properly handle both directional embeddings as well as directional isolates to determine the direction of the string. According to the latest version of the Unicode bidi algorithm, parts of the string contained inside an directional isolate is to be ignored when determining the paragraph direction. Embedding markers themselves are to be ignored as well, but not the characters inside an explicit directional embedding or override. This is also some required pre-work to get our BiDi algorithm updated to the latest version of the standard. Move the implementation to QStringView and implement the methods in QString and QStringRef through that implementation. Task-number: QTBUG-57743 Change-Id: I7f24e09198e22d6359c6534c9ae40a904e94c46e Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.10' into dev" into ↵Liang Qi2018-01-0225-237/+438
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.10' into devLars Knoll2018-01-0225-237/+438
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf sc/corelib/io/qfsfileengine_p.h src/corelib/io/qstorageinfo_unix.cpp src/platformsupport/eglconvenience/qeglpbuffer_p.h src/platformsupport/input/libinput/qlibinputkeyboard.cpp src/platformsupport/input/libinput/qlibinputpointer.cpp src/plugins/platforms/cocoa/qcocoamenu.mm src/plugins/platforms/ios/qiosscreen.h src/plugins/platforms/ios/qioswindow.h src/plugins/platforms/ios/quiview.mm src/printsupport/dialogs/qpagesetupdialog_unix_p.h src/printsupport/dialogs/qprintpreviewdialog.cpp src/printsupport/widgets/qcupsjobwidget_p.h src/widgets/widgets/qmenu.cpp tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp Change-Id: Iecb4883122efe97ef0ed850271e6c51bab568e9c
| | * | Merge remote-tracking branch 'origin/5.9' into 5.10Lars Knoll2017-12-3017-89/+318
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf mkspecs/win32-g++/qmake.conf src/corelib/global/qglobal_p.h src/corelib/global/qoperatingsystemversion_p.h src/corelib/io/qfilesystemengine_win.cpp src/network/bearer/qbearerengine.cpp src/platformsupport/input/libinput/qlibinputpointer.cpp src/sql/doc/snippets/code/doc_src_sql-driver.cpp src/widgets/kernel/qwidget_p.h src/widgets/kernel/qwidgetwindow.cpp src/widgets/styles/qfusionstyle.cpp tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp Change-Id: I80e2722f481b12fff5d967c28f89208c0e9a1dd8
| | | * Blacklist tst_QUdpSocket on Ubuntu 16.04Joni Jantti2017-12-271-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tst_QUdpSocket::broadcasting and tst_QUdpSocket::pendingDatagramSize fail on the new Ubuntu 16.04 clean template. Task-number: QTBUG-65440 Change-Id: I0e973b9c90b7c5827406bac8138370b61992a115 Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
| | | * Blacklist tst_QDateTime::operator_eqeqJoni Jantti2017-12-271-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This autotest fails on the new Ubuntu 16.04 template with UTC timezone in the system settings. Task-number: QTBUG-65435 Change-Id: I397f01ab3fed354a4eeec8b05415226a75fce5a1 Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
| | | * qfloat16: NaN is not infiniteThiago Macieira2017-12-271-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I39332e0a867442d58082fffd1502b7010424f0f8 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| | | * Use AccessCheck for current user effective file permissionsDyami Caliri2017-12-211-6/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Windows, QFileInfo.isWritable() was returning true in situations where the file would only be writable with elevated privileges. Using AccessCheck instead of GetEffectiveRightsFromAcl to get the correct results. Done-with: Friedemann Kleint <Friedemann.Kleint@qt.io> Done-with: Edward Welbourne <edward.welbourne@qt.io> Task-number: QTBUG-30148 Change-Id: I7a3468ac069bf782ca312078e3a84107b6cd468c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | | * Don't crash with null receiver/context in new-style connectsSergio Martins2017-12-191-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | old style connects have protection against null sender and null receiver, but new style only had against null sender. Change-Id: Ie555ac078412918e60c3b60830fe1f3abfb7f5af Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
| | | * QTreeView: Make sure QHeaderView is notified on layoutChanged()Christian Ehrlicher2017-12-171-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QHeaderViewPrivate::_q_layoutChanged() was not called when used in a QTreeView because it was explicitly disconnected in setModel(). The disconnect was added sometime prio to Qt 4.3, but there the signal was connected to the doItemsLayout() slot. This was correct since QTreeView::doItemsLayout() is calling header->doItemsLayout(). In Qt 4.3.0 _q_layoutChanged() was introduced and the disconnect was adjusted. But since _q_layoutChanged() is doing much more than doItemsLayout() (e.g. restoring hidden sections), functionality was lost. The problem was already observed for Qt 4.6 (QTBUG-18196) but only partially fixed. Task-number: QTBUG-41124 Task-number: QTBUG-54610 Change-Id: Id13a9930d0163812e12a0287016bab9c3aa02068 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
| | | * Fix assert when emitting a signal from a different threadJesus Fernandez2017-12-141-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a signal is emitted more than once in a multithreaded application the QSignalEventGenerator::execute function asserts in the check for a valid signal index. It happens after abandoning the state and all the connections are disconnected. If we have pending signal to be processed the QObject::sender() won't be able to resolve the sender object. Task-number: QTBUG-61463 Change-Id: I9d4b7266c6dddc9ff2e7453b05a6989876ccb332 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
| | | * Fix typoOliver Wolff2017-12-131-3/+3
| | | | | | | | | | | | | | | | | | | | Change-Id: If6111c59b958ba03f6ec5966af5cf443cae5cf9b Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| | | * Set sharedPainter correctly for QGraphicsEffectLaszlo Agocs2017-12-121-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Autotest is taken from the previously reverted 8b1377fde16a2049a1c27f6d005bff84a8f85f28. Task-number: QTBUG-60231 Change-Id: I44dd79cba22b6baefdd6d95c176790bef0b7eafe Reviewed-by: Andy Nichols <andy.nichols@qt.io>
| | | * tst_QUdpSocket: fix linkLocalIPv4 testThiago Macieira2017-12-051-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I broke it in commit 4da2dda2aa1f710177157dc1cf841e0bf0b9d829. It wasn't flaky or anything: it was plain broken and would never pass. That indicates no node in the CI has an IPv4 link-local address (and apparently neither did I at the time). Change-Id: Ifb5969bf206e4cd7b14efffd14fb62176546916e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
| | | * tst_QUdpSocket: Don't test for .bytesAvailable on untrusted platformsThiago Macieira2017-12-051-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FreeBSD, for example, does not have SO_NREAD and its FIONREAD returns the full socket buffer size, including IP and UDP headers. Change-Id: Ifb5969bf206e4cd7b14efffd14fb5d8ca778d16a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
| | | * Use a custom QAnimationDriver to take control over timeJan Arve Sæther2017-12-022-74/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This should reduce flakyness of tests. Change-Id: I26e0a97f7cd3e7cee2ffb44188300c37578cddd7 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
| | | * macOS: Blacklist: tst_QPropertyAnimation::startWithoutStartValue()Friedemann Kleint2017-12-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-64108 Change-Id: Id60a9a1bfede9cbe90f378d131a331d726acfdae Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
| | | * macOS: Blacklist tst_QPauseAnimation::noTimerUpdates()Friedemann Kleint2017-12-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-64107 Change-Id: Ie77d2d2525e79fb7e17f1a69d15ef40982f9242d Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
| | | * tests/auto/auto.pro: Use correct null device for DBUS checkFriedemann Kleint2017-12-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A mysterious file c:\dev\null appeared when running the auto tests on Windows. Fix by using QMAKE_SYSTEM_NULL_DEVICE. Amends 5f3529be32df3cce81e77c3dbb76cfda7feb320c. Change-Id: I0224a9ccd61c4f10b2ddb8f8d690e1849aa88d8a Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
| | | * Blacklist tst_QSplitter::replaceWidget(visible, not collapsed) for LinuxFriedemann Kleint2017-12-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test is flaky on Linux. Task-number: QTBUG-64639 Change-Id: Iec56ebce4f656f52187b34c8f655b137e41c3d17 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
| | | * tst_QFileSystemModel: Stabilize readOnly(), sortPersistentIndex()Friedemann Kleint2017-11-301-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The tests start to show flakyness on Linux in 5.10 (rowCount() check failing). This seems to point to a race condition between the files showing up and the file system watchers of QFileSystemModel starting. To fix this, close the file and wait until it shows up in the directory before pointing the QFileSystemModel to it. The tests then no longer rely on the file system watchers. Change-Id: I39cffb4cacf6843e8e4180efb405345307c78dd8 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
| | * | tst_QUdpSocket: add some tests for link-local IPv6 multicastingThiago Macieira2017-12-291-1/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Unlike higher scopes (like scope 4, admin-local, which the last commit used), scopes 1 and 2 require a scope in order to bind, even if some operating systems are lenient. So test that we are able to bind to them and do bind properly. Change-Id: Ifb5969bf206e4cd7b14efffd14fba153eab965b9 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| | * | tst_QUdpSocket: always use an interface when binding to IPv6Thiago Macieira2017-12-292-6/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Binding without an interface and expecting the OS to select something is not supported in all OSes. On FreeBSD, I keep getting EADDRNOTAVAIL. So modify our test to only join, leave and send to multicast groups with an interface selection. With this, all tests either pass or are skipped for me on Linux, FreeBSD, and macOS. On Windows, this revealed an inconsistency in behavior, which this commit adds a workaround for. Change-Id: Ifb5969bf206e4cd7b14efffd14fb6815456494d2 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| | * | tst_QUdpSocket: Don't use interface-local IPv6 multicastThiago Macieira2017-12-241-6/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The FreeBSD kernel treats them specially, just like link-local (that's probably why it calls them "interface-local" instead of "node-local"). So instead let's use a random address, which will avoid multiple tst_qudpsocket, when run on the same network at the same time, receiving each other's datagrams. It could happen, considering this test has an 800-second timeout limit. Change-Id: Ifb5969bf206e4cd7b14efffd14fb592a3166547e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
| | * | tst_QUdpSocket: stop trying to bind to multicast addressesThiago Macieira2017-12-242-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is not an official feature of the networking stacks and does not work portably across operating systems. So just stop trying to do that. This was failing reliably (not flaky!) with IPv6 on FreeBSD and Windows. For IPv4, Windows apparently accepts 239.255.0.0/16 but not other addresses, so remove IPv4 too. Change-Id: Ifb5969bf206e4cd7b14efffd14fb682c2839e95d Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
| | * | Merge remote-tracking branch 'origin/5.10.0' into 5.10Liang Qi2017-12-085-9/+26
| | |\ \ | | | | | | | | | | | | | | | Change-Id: I6dcf85067ec226136c207ea69ca9d66736c84db5
| | | * | Improve readability of code that uses the Qt signed size typev5.10.0-rc2Simon Hausmann2017-11-282-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | During the container BoF session at the Qt Contributor Summit 2017 the name of the signed size type became a subject of discussion in the context of readability of code using this type and the intention of using it for all length, size and count properties throughout the entire framework in future versions of Qt. This change proposes qsizetype as new name for qssize_t to emphasize the readability of code over POSIX compatibility, the former being potentially more relevant than the latter to the majority of users of Qt. Change-Id: Idb99cb4a8782703c054fa463a9e5af23a918e7f3 Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch> Reviewed-by: David Faure <david.faure@kdab.com>