The generated xml file is now lowercase.
This was changed in shared-mime-info 3805d0bcf2.
It led to runtime warnings "No file found for ...", which helped notice the bug.
Change-Id: I31f0fc7f0fe8a098c3f79c0bcbeeb1909d2cc05a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The buffer may have been left dirty if we were unable to write all the
data to the child process in the previous run. So ensure we clear it
before starting a new one. We already did that for stdout and stderr,
for some reason.
Task-number: QTBUG-44517
Change-Id: I1a800c709d3543699131ffff13c419da3bbffacf
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
It failed on Windows due to readonly files copied from the resource,
until adding a setPermission call.
Change-Id: I1d42b53763583aca73d011e0f2bbf061ef6aa891
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
On Windows and OS X, where QStandardPaths does not use XDG_DATA_DIRS/
_HOME and shared-mime-info is not installed, the tests that require
additional shared mime info xml files were never run.
Mend that by using QStandardPaths' test mode instead of setting
XDG_DATA_HOME.
Change-Id: I53b75c293c41c4dac63986dcb88972c2b54d5428
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: David Faure <david.faure@kdab.com>
The test is very flakey in 5.5 integrations and the OS X CI machines have
notorious problems with networking stability. So the previously listed tests
are not really at fault, it's an infrastructure problem, that we choose to
ignore for the time being.
Change-Id: I7fbfa7b3778daa6b5e60d95b822847c92927122f
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
The former didn't account for ascent and descent.
Change-Id: If741f22f7e79ac3c13e58f2966358010d9f9ec81
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
[ChangeLog][Important Behavior Changes] QDebug output for QStrings
changed compared to Qt 5.5.0 to more closely match the output of
previous Qt versions. Like Qt 5.5.0, QDebug will escape non-printable
characters, the backslash and quote characters, but will no longer
escape the printable characters.
Task-number: QTBUG-47316
Change-Id: I52dd43c12685407bb9a6ffff13f62ef68cbc80c5
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Otherwise, on some systems (Windows), we'll always create the same dirs.
Change-Id: Id3d5c7bf4d4c45069621ffff13f79ba91e0f974b
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
[ChangeLog][QtCore][QLoggingCategory] Fixed behavior of default
severity passed to constructor or Q_LOGGING_CATEGORY with regards to
QtInfoMsg, which was previously treated as being more severe than
QtFatalMsg.
This is because the code was using the numeric value of QtMsgType as a
proxy for severity (via the <= operator), but the value of QtInfoMsg is
greater than QtFatalMsg. Instead, the severity ordering must be dealt
with explicitly.
Change-Id: I5f178afc735221b00cb67c2cea4fa964bd9079ce
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Build it only in -developer-build mode for tests that might depend
on exact-matching font behavior.
Return earlier to avoid doing any useless job.
Change-Id: I966ee5689f03403e45f4c957b63e3113f0467803
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
The QSslCertificate tests only covered certificates with RSA keys, this
extends the test coverage to DSA and EC keys.
Change-Id: Ibee26f449cf6c1d97cbac6b511972eb44d6f0bd2
Reviewed-by: Richard J. Moore <rich@kde.org>
All overloads of QProcess::start will now check whether the program
string is empty and in that case
- set error to FailedToStart,
- set errorString to "No program defined",
- emit error.
Until now only one of the three overloads behaved like this.
As a side effect, start(QString(), QStringList()) will not crash on
Windows anymore.
Task-number: QTBUG-47404
Change-Id: I2f93657204fe3643b1d74a74817843c05fc4a96b
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
The comment about non-OpenSSL backends not reproting a specific error
for self-signed certificates contained a typo, this fixes it.
Change-Id: I3010981d5d87d68ebf5e984c003b8bbbfb019b96
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
Non-OpenSSL backends are not able to report a specific error code
for self-signed certificates.
Change-Id: I56bf130335b2afa65cf2bd5248a40ac0e32f74c2
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
Set QFileDevice::WriteUser on all files extracted from resources. These
are read-only, which is preserved by QFile::copy(). This caused the
deletion of the temporary directory to fail on Windows.
Change-Id: Id99de9160471c38bcec68025c89cfabbe209bdbe
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: David Faure <david.faure@kdab.com>
Otherwise, if I open tests/auto/dbus/dbus.pro in Qt Creator, it shows me
"test", "test2", "test3", "test4" and it's very hard to know which test
is which.
Change-Id: Iee8cbc07c4434ce9b560ffff13d0654696c025b7
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
I'm getting an error with WSARecvFrom in nativeBytesAvailable() and I
don't know why. The number of bytes obtained is correct and the test
works for 2 bytes, so let's use that.
The Windows nativeBytesAvailable() function has a comment saying that
WSAIoctl sometimes indicates 1 byte available when there's a pending
error notification, so that function proceeds to do a WSARecvFrom to
peek the number of bytes. Somehow that function in this test is getting
a SOCKET_ERROR I can't explain.
Change-Id: Ic5b19e556e572a72a9df9a405b1fee3b7efb8b24
Reviewed-by: Richard J. Moore <rich@kde.org>
On Windows, having read-only files in a directory can cause removal
to fail. When file deletion fails, check on the permissions, set
write permissions and retry.
Split apart code paths by OS in tst_QDir::removeRecursivelyFailure();
deletion of the read-only directory on UNIX should still fail.
Change-Id: I36e54be5229a7b552e90fd5f42722b868fa0b6ee
Reviewed-by: David Faure <david.faure@kdab.com>
The test showed failures on OS X:
FAIL! : tst_QListView::batchedMode() Compared values are not the same
Actual (ba.size()): 2
Expected (3) : 3
Loc: [tst_qlistview.cpp(848)]
Use QTRY_COMPARE() to count the number of visible indexes with
a helper function instead of using hard-coded timeouts. Item 3
appears with a little delay on OS X.
Change-Id: I2fb2ff5ebdf9dbe85bdc79401375ad6f47b7b12b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
The test checks whether a child window receives
mouse events synthesizes from touch. Enlarge the child
window so that it fully covers the parent and move the
touch point a bit inside so that it is not affected
by window manager positioning issues.
Use QTRY_VERIFY.
FAIL! : tst_QApplication::touchEventPropagation() 'widget.seenMouseEvent' returned FALSE. ()
Loc: [/work/build/qt/qtbase/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp(2107)]
Change-Id: Ic08e68b1e547cc7148cd8994464fdc2a14ac507b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
The test sends touch events to the root item at the top left
corner which fails if the views starts to scroll.
Make the view sufficiently large to prevent scrolling and align
at top left.
FAIL! : tst_QTouchEvent::touchBeginWithGraphicsWidget() Compared values are not the same
Actual (((root->touchBeginCounter))): 0
Expected (1) : 1
Loc: [/work/build/qt/qtbase/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp(1471)]
Change-Id: I357322ccc809ddb5cb587febf3c75cbe497e59d8
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
An object that throws in its constructor cannot be reentered. This
violates both C++11 and C++98. It's also a regression from MSVC 2013.
The unit test is renamed to indicate what it really does, as opposed to
a misleading name that was probably a "thinko" on my part.
Task-number: QTBUG-47224
Change-Id: Ib306f8f647014b399b87ffff13f132436d0578ef
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
QTemporaryFileEngine does not store the pattern, so it needs to get it
again from QTemporaryFilePrivate prior to reopening the file. It's
possible to lose the pattern when remove() is called on the object.
Task-number: QTBUG-46156
Change-Id: I66a35ce5f88941f29aa6ffff13dfc7f83d4fa3a2
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: David Faure <david.faure@kdab.com>
This is a fix-up for cff39fba10.
That patch lead to some internal state issues that lead to the QTBUG-47048
or to QNetworkReply objects erroring with "Connection Closed" when
the server closed the Keep-Alive connection.
This patch changes the QNAM socket slot connections to be DirectConnection.
We don't close the socket anymore in slots where it is anyway in a closed state
afterwards. This prevents event/stack recursions.
We also flush QSslSocket/QTcpSocket receive buffers when receiving a disconnect
so that the developer always gets the full decrypted data from the buffers.
[ChangeLog][QtNetwork] Fix HTTP issues with "Unknown Error" and "Connection Closed"
[ChangeLog][QtNetwork][Sockets] Read OS/encrypted read buffers when connection
closed by server.
Change-Id: Ib4d6a2d0d988317e3a5356f36e8dbcee4590beed
Task-number: QTBUG-47048
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
On Windows, t->timeout was updated only once, at creation time, so the
timer would always show as "overdue" after the first activation.
The timer is updated to indicate the full remaining time during the slot
activation, which is the behavior of the Unix and Glib dispatchers.
Task-number: QTBUG-46940
Change-Id: I255870833a024a36adf6ffff13ecadb021c4358c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Sending several key presses with repeat=true should trigger the action
several times, unless autoRepeat is set to false.
Change-Id: I6469bbd78a608a87852554882c1632ce34422662
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Keeping the reference may end up in a crash if a created
QIcon outlives the QFileIconProvider and we then try to
generate a pixmap.
The reference is not necessary since the options are queried
only when creating the icon, so they can be saved in the icon
provider.
Task-number: QTBUG-46755
Change-Id: I5c60887c2ed39030a2a20298ff10fd652189e4e7
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
When executing the test in a sequence (as done by make check after
tst_qstackedlayout), tst_QToolTip::task183679 often fails since
apparently the tooltip is hidden when the cursor is near it.
Move to the cursor to the right corner of the widget to fix this.
Change-Id: I3b13239e77cb387f1b1425fab79c8d6faa27b5bb
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Conflicts:
src/plugins/platforms/cocoa/qcocoafiledialoghelper.h
Manually fixed src/testlib/qtestcase.cpp to return the right type.
Change-Id: Id1634dbe3d73fefe9431b9f5378846cb187624e4
f9408317e7 was unfortunately
approved though it had an annoying bug. The patch had
an assign of a visual index into a logical index.
This patch fixes that issue.
Change-Id: I9cc75e4e9701858c92e2c3e5817415041b42f8e8
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Merely filling with Qt::transparent is not enough, as the default blend
mode of QPainter is QPainter::CompositionMode_SourceOver, where the alpha
of the source is used to blend the pixel on top of the destination. The
destination in the case of an FBO may contain garbage, and we end up with
the same garbage as the alpha is 0.
This was evident when running the ellipses and porter_duff/porter_duff2
tests on OS X. These tests can now be un-blacklisted.
Change-Id: I315fa764fa29fb3a06e38945a738a6feadf4502d
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
The test tried to position the mouse cursor over item #0 . This
sometimes results in the cursor being outside the window when
the window manager adds the window decoration on X11.
Move the cursor to the center of the window instead.
Add cleanup slot checking top level leaks, remove empty
functions.
Change-Id: I908240e1cc3fdbe370b43eae0015272ca342a312
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
The rationale being that the empty string is not a valid path component.
[ChangeLog][QtCore][QDir] QDir::relativeFilePath() now returns "."
instead of an empty string if the given path is the same as the
directory.
Change-Id: Ibcf31904b2ae5edf5639d4c2e5ba234365d347fd
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Since of Windows (Phone) 8.1 most of the desktop's thread functionality
is also available, so we might be able to share the code and get rid of
the extra implementation for WinRT.
Task-number: QTBUG-43837
Change-Id: I0ce907cd94899834527f88c70e1e395bafdb14b3
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
ad9698713f reduced the curvethreshold
for wide lines, to fix QTBUG-46151. But as a side effect, the
threshold was increased for lines of widths >=0 and <4. This commit
fixes that, and also adds a lance test for the issue in QTBUG-46151.
Change-Id: I52507db622435fe1d2646640cb0bd9cd8222e453
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Move the code path handling widgets embedded in QGraphicsProxyWidget
into the loop moving up the parent hierarchy.
Add child widget to test.
Task-number: QTBUG-41135
Change-Id: Ibd86413faaa927145a85a2f5864f162979135053
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
The Intel compiler defaults to "fast math" mode, which is why those
tests had been failing. So for the test that is trying to check whether
we conform to IEEE strict requirements, turn on strict requirements.
Change-Id: I02f8426b1c8e4241ac10ffff13e8efa224f313b2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>