summaryrefslogtreecommitdiffstats
path: root/tests/auto/network/socket/qsocks5socketengine
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-01-151-1/+2
|\ | | | | | | Change-Id: I8dbcf23835d52d3aa7d018ed250814d60c68aa83
| * Skip instead of fail tests when test server is not availableTor Arne Vestbø2020-01-141-1/+2
| | | | | | | | | | | | | | | | | | | | We were being inconsistent in how we handled this, some tests skipping while others using QVERIFY. It makes more sense to skip the tests, since the problem is a missing pre-condition of the test, not the test itself being bad or exposing real failures in the implementation. Change-Id: I20eacfe12dbce0b0d926e48cbe2d2772819fa4a5 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | QAbstractSocket: deprecate 'error' member-functionTimur Pocheptsov2020-01-101-2/+2
|/ | | | | | | | | | | | The one that is a getter for the last error found. This is to disambiguate the expression '&QAbstractSocket::error'. Introduce a new member-function socketError as a replacement. [ChangeLog][Deprecation Notice] QAbstractSocket::error() (the getter) is deprecated; superseded by socketError(). Task-number: QTBUG-80369 Change-Id: Ia2e3d108657aaa7929ab0810babe2ede309740ba Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* Update for failures only on dev branch. Use general platform namesDaniel Smith2019-08-191-2/+1
| | | | | | | | | | This patch was generated with tooling from patchset 31 of https://codereview.qt-project.org/c/qt/qtqa/+/267034 in interactive mode. General platform names were chosen if greater than 60% of the currently active platforms of a given type in COIN recently failed. Change-Id: Ia4bde7f0ec422bbb727dc9d7151295159094f146 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* unblacklist passing testsDaniel Smith2019-07-081-5/+6
| | | | | | | | These tests have not failed on the removed platforms for at least 60 days Task-number: QTBUG-76608 Change-Id: If7a9f4db907124e3cd54e3f4b0ad3e20717d1912 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Expose docker test server as an internal config to all modulesRyan Chu2019-04-251-1/+1
| | | | | | | | | | | | | Before testserver becomes a stable feature, let's keep testserver.prf in "mkspecs/features/unsupported". The test server's shared files will be stored in "mkspecs/features/data/testserver". Because the path of testserver has been changed, all the tests relying on the docker servers should be updated as well. Change-Id: Id2494d2b58ee2a9522d99ae61c6236021506b876 Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Blacklist tst_qsocks5socketengine::passwordAuth2Mårten Nordheim2019-03-011-0/+3
| | | | | | | | | It's flaky and has been for a while. However it is somewhat more flaky when using the docker setup. Task-number: QTBUG-74162 Change-Id: I49f346a39271b48395e0e17fa6821d73a24f81d4 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Convert the QSocks5SocketEngine test to use DockerMårten Nordheim2019-02-282-18/+30
| | | | | Change-Id: I5d223758471a72c93ad57d250001c1de51a208cd Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* tst_QSocks5SocketEngine::downloadBigFile(): Output elapsed timeFriedemann Kleint2017-06-281-7/+8
| | | | | | | | | Print time in the error handler to get some diagnostics about when the network connection is dropped. Task-number: QTBUG-61673 Change-Id: I376bec81f52d75c9b601f2af9b7e0b63f5883bb0 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Blacklist tst_QSocks5SocketEngine::downloadBigFile()Friedemann Kleint2017-06-281-0/+2
| | | | | | Task-number: QTBUG-61673 Change-Id: Id81446e52c6492a22347de708b4785f55a1b0d5d Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* tst_QSocks5SocketEngine: Refactor testsFriedemann Kleint2017-01-231-88/+52
| | | | | | | | | | | Rewrite tcpSocketNonBlockingTest() and downloadBigFile() to use lambdas for the slots. This allows for removing the related member variables and slots of the test class and ensures no leaks of sockets or inconsistent values. Add an error handler printing the error message to the flaky downloadBigFile() test. Change-Id: Ieb64063c41e045a1a50a6d074bef01753ee319ef Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* Use qtConfig throughout in qtbaseLars Knoll2016-08-191-1/+1
| | | | | | | | | | | Use the new qtConfig macro in all pro/pri files. This required adding some feature entries, and adding {private,public}Feature to every referenced already existing entry. Change-Id: I164214dad1154df6ad84e86d99ed14994ef97cf4 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* QtNetwork: Remove Windows CE.Friedemann Kleint2016-03-291-4/+0
| | | | | | | | | Remove #ifdef sections for Q_OS_WINCE and wince .pro file clauses in library, examples and tests. Task-number: QTBUG-51673 Change-Id: I3706336395620522ceda414d7437295d9ec64f16 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Updated license headersJani Heikkinen2016-01-211-17/+12
| | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I42a473ddc97101492a60b9287d90979d9eb35ae1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Tests: Remove empty init/cleanup slots, constructors and destructors.Friedemann Kleint2015-12-101-20/+1
| | | | | | | | Move some code (like registrations of meta types) from init() to initTestCase() in the process. Change-Id: I57db5156647cfadab554fbed853b2e68b2815f3b Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* Tests: Use QCOMPARE() with QLatin1String() for QString values.Friedemann Kleint2015-10-141-6/+6
| | | | | | | Prefer QCOMPARE over QVERIFY for equality and use QLatin1String(). Change-Id: If226a0fc7b25be3e6774c7e36ca1e6f99234e5dd Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
* QAbstractSocketEngine: introduce QIpPacketHeader for datagramsThiago Macieira2015-08-221-7/+7
| | | | | | | | | | | | | | | | | | | This commit changes the readDatagram() and writeDatagram() virtual functions to take a QIpPacketHeader as meta data, instead of a QHostAddress/quint16 pair. As previously, the header is an "out" parameter for readDatagram() and an "in" parameter for writeDatagram(). The header pointer in readDatagram() is allowed to be null if the PacketHeaderOptions indicates WantNone. Otherwise, it must not be null. The extra options parameter is introduced because we may not always want all the metadata upon reception. For sending, we know what to include or not based on what's set in the incoming header parameter. QIpPacketHeader splits sender and destination because we'll be able to return both on datagram reception. Change-Id: Iee8cbc07c4434ce9b560ffff13ca4213255008c7 Reviewed-by: Richard J. Moore <rich@kde.org>
* tests/auto/network: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).Friedemann Kleint2015-07-311-53/+53
| | | | | | | | | | | | - Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer). - Replace Q[TRY]_VERIFY(smartPointer == 0) by Q[TRY]_VERIFY(smartPointer.isNull()). - Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) and add casts where necessary. The values will then be logged should a test fail. Change-Id: Icaa1edafcc6e2779fbd6dbc2c058544d6e07f1e9 Reviewed-by: Richard J. Moore <rich@kde.org>
* Blacklist socks bind test on WindowsSimon Hausmann2015-06-201-0/+2
| | | | | | | The test is very flakey. Change-Id: I6cb7ee7989169d077104883a02bb9240bafabe38 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Remove the tests for Ubuntu Oneiric (11.10)Thiago Macieira2015-03-171-2/+0
| | | | | | | | | | | | | | | | | | This system is no longer in the CI rotation and we haven't had reports of the same issues happening on later versions. Either the issues have since been fixed or they were never an issue in Qt in the first place. This commit has the additional benefit of getting rid of the following shell error when qmake was run: sh: line 0: [: =: unary operator expected as /etc/lsb-release hasn't contained DISTRIB_CODENAME for some time and proper quoting was never implemented (not even qtcpsocket.pro). Change-Id: Ia0aac2f09e9245339951ffff13c829e910ee64e9 Reviewed-by: Albert Astals Cid <albert.astals@canonical.com> Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com> Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update copyright headersJani Heikkinen2015-02-111-7/+7
| | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* Fix how qsocks5socketengine autotests are blacklistedTony Sarajärvi2014-11-201-0/+2
| | | | | Change-Id: I6436491267b737fc00c33af7bd9491510c21b7c5 Reviewed-by: Simon Hausmann <simon.hausmann@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>
* Update license headers and add new license filesMatti Paaso2014-09-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 - Removed LICENSE.GPL Change-Id: Iec3406e3eb3f133be549092015cefe33d259a3f2 Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
* Socks5 socket engine test: Disable UDP over Socks testPeter Hartmann2014-05-211-10/+4
| | | | | | | | | | | ... because it fails on the new network test server. The Socks5 tests in QUdpSocket have already been disabled by commit aa3eaf9d2ec4927df51e7d773a66f68ec5e4fce9 . Task-number: QTBUG-35490 Change-Id: Ib062adb422ff6e5538f14d15a266d79c3bb53956 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Tony Sarajärvi <tony.sarajarvi@digia.com>
* QtNetwork tests: Remove DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0Sergio Ahumada2014-02-251-1/+0
| | | | | Change-Id: If1cc5fafddc41ed19dd818caf294c69cd4969216 Reviewed-by: Richard J. Moore <rich@kde.org>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-181-1/+1
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Network: Remove declaration of built-in and automatic metatypes.Stephen Kelly2013-01-031-2/+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>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-221-24/+24
| | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: If1cc974286d29fd01ec6c19dd4719a67f4c3f00e Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* QtNetwork: Handle FD_CLOSE on WindowsMartin Petersson2012-08-011-0/+1
| | | | | | | | | | | | | We need to handle FD_CLOSE separately on Windows as this will be sent only once. When we get FD_CLOSE we need to check if there is more data available for reading. It there is this might indicate that there is another FD_READ that we need to handle after the FD_CLOSE. So in this case we will manually create another close event. Task-number: QTBUG-19409 Task-number: QTBUG-25386 Change-Id: Ie19906bc3f64fb6a85a508a5ab12caac5d70ccdb Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Set the Qt API level to compatibility mode in all tests.Thiago Macieira2012-08-011-0/+1
| | | | | | | | | | | Qt 5.0 beta requires changing the default to the 5.0 API, disabling the deprecated code. However, tests should test (and often do) the compatibility API too, so turn it back on. Task-number: QTBUG-25053 Change-Id: I8129c3ef3cb58541c95a32d083850d9e7f768927 Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Handle fragmented responses on SOCKS5 control channelShane Kearns2012-06-211-19/+138
| | | | | | | | | | | | Server responses may arrive in more than one packet, though this is rare due to nagle algorithm. Also fixed IPv6 addresses being discarded from server responses, which was caught by the new autotest. Task-number: QTBUG-18564 Change-Id: I32d9e2978037fb3e1fff27b7e618b5da6d222f28 Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
* Don't use obsolete qVariantValue, qVariantCanConvert, etc.Debao Zhang2012-05-021-2/+2
| | | | | | | | | | qVariantValue and qVariantCanConvert are Compatibility members, while in Qt4.8 they are marked as Qt 3 Support Members. qVariantFromValue and qVariantSetValue are Obsolete members. Change-Id: Ie8505cad1e0950e40c6f6710fde9f6fb2ac670fd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Remove insignification of qsocks5socketengine on Ubuntu 11.10Jason McDonald2012-04-192-1/+10
| | | | | | | | | | | The test has one stable failure on CI, but that failure is not observed by all Ubuntu 11.10 users. Mark that failure with QEXPECT_FAIL when it is going to fail and re-enable the test, following the pattern established for the qtcpsocket test on this platform. Task-number: QTBUG-23380 Change-Id: Ic7546595f314c55ebd36957ada92978141a1c509 Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Put bug numbers on same line as insignificant_test markers.Jason McDonald2012-04-161-2/+1
| | | | | | | | This makes it easier to find insignificant tests that have no associated bug report. Change-Id: Ia71d59da062818d3860b0365d063e044705267fd Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Removing QHttp class, its tests and its usage in examples.Jonas M. Gastal2012-01-061-1/+0
| | | | | | Task-number: QTBUG-22750 Change-Id: I161fad772bfb26797e6ee9d69da925b6747c371f Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Flag udpTest as insignificant, fails on Ubuntu 11.10 x64.Toby Tomkins2011-12-301-0/+3
| | | | | | | | | | This testcase fails on the Ubuntu 11.10 x64 platform, add flag to .pro file so test is ignored on this platform. Task-number: QTBUG-23380 Change-Id: I51831df8c8e9bfcf63d3689e37552ca1a62691cd Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix sanity check of network test serverJason McDonald2011-11-281-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some of Qt's autotests depend on access to a test server. For each test that used the test server, tests/auto/network-settings.h created a global object to verify at startup that host lookups to the test server will succeed (and abort the test otherwise). There are two problems with that approach: First, the sanity check happens before main(), and thus before the test framework has started logging test results. This means that if the sanity check aborts the test, the failure message will not be visible in the test output if logging to a file or will cause the output to be malformed if logging to the console in XML format. Second, since Qt 4.7, the host lookup uses a class that connects to the QCoreApplication instance, which doesn't exist before main(), and this caused all tests that included network-settings.h to output an error message from QObject::connect() at the beginning of the test. Both of these problems are solved by removing the global object from network-settings.h and instead performing the sanity check in the initTestCase() function of each test. Task-number: QTBUG-22876 Change-Id: Id49c1826906327bf571686cc11527f0265e5af44 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* all remaining tests: eliminated usage of qttest_p4.prfRohan McGovern2011-10-251-2/+3
| | | | | | | | | qttest_p4.prf was added as a convenience for Qt's own autotests in Qt4. It enables various crufty undocumented magic, of dubious value. Stop using it, and explicitly enable the things from it which we want. Change-Id: I02fe27b2c1800f929250fa8694ca2976c9661a12 Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Remove Symbian-specific code from tests.Jason McDonald2011-09-292-11/+1
| | | | | | | | | Symbian is not a supported platform for Qt5, so this code is no longer required. Change-Id: I1172e6a42d518490e63e9599bf10579df08259aa Reviewed-on: http://codereview.qt-project.org/5657 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Moved network autotests into new directory structureJo Asplin2011-09-093-0/+981
Task-number: QTBUG-21223 Change-Id: I55dbf5c42a1c5d938b9e0c9bf7d90457a6c26bbc Reviewed-on: http://codereview.qt-project.org/4259 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>