summaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
* QNetworkCookie: allow spaces in unquoted valuesPeter Hartmann2011-04-291-0/+8
| | | | | | | | | | We should follow http://tools.ietf.org/html/draft-ietf-httpstate-cookie-23 , which says parse the value until reaching the next ';' or the end of the line. Other cookie implementations allow spaces in unquoted values as well. Reviewed-by: Martin Petersson Task-number: QTBUG-18876
* fix tst_qscriptengine after merging MR-1149Zeno Albisser2011-04-281-0/+2
| | | | Reviewed-by: Olivier Goffart
* Add test for ISODate change in QDateTime::toStringJens Georg2011-04-271-0/+32
| | | | | Merge-request: 1149 Reviewed-by: Zeno Albisser <zeno.albisser@nokia.com>
* Merge remote-tracking branch 'earth-team/master' into earth-staging-masterOlivier Goffart2011-04-2048-273/+1073
|\
| * QNetworkCookie: do not access date string out of boundsPeter Hartmann2011-04-201-0/+1
| |
| * Fix compile error with QT_NO_OPENSSLShane Kearns2011-04-191-0/+2
| |
| * Fix qfile autotest hanging in CI systemShane Kearns2011-04-191-3/+8
| | | | | | | | | | | | | | | | | | | | | | The test machine is configured to pop up dialogs in case of CRT assertion failures. The CRT has a debug assert whenever an invalid file handle is used, while the test is expecting to get the EBADF return code. Due to some behaviour change in windows 7 (maybe SP1), we need to call _CrtSetReportMode in addition to setting an error handler. Reviewed-By: mread
| * QLocale: Fixed double to currency string conversion on Mac.Denis Dzyubenko2011-04-141-3/+3
| | | | | | | | | | | | This also fixes the autotest failure on mac with macDefaultLocale test. Reviewed-by: trustme
| * Added support for libICU for collation and toLower/toUpper.Denis Dzyubenko2011-04-122-0/+57
| | | | | | | | | | | | | | | | | | | | | | This patch uses icu to do string collation via QString::localeAwareCompare function and for QString::toLower/toUpper - which is important e.g. for turkish locales where uppercased 'i' is not a latin 'I'. Based on the patch by Harald Fernengel Reviewed-by: Harald Fernengel Reviewed-by: Zeno Albisser
| * Merge branch 'symbian-socket-engine' of scm.dev.troll.no:qt/qt-symbian-networkShane Kearns2011-04-1244-270/+1005
| |\ | | | | | | | | | | | | | | | | | | | | | Conflicts: configure.exe src/s60installs/bwins/QtCoreu.def src/s60installs/bwins/QtGuiu.def src/s60installs/eabi/QtCoreu.def
| | * Merge remote branch 'earth/master' into symbian-socket-engineShane Kearns2011-04-111-20/+15
| | |\ | | | | | | | | | | | | | | | | Conflicts: tests/auto/qabstractnetworkcache/tst_qabstractnetworkcache.cpp
| | * \ Merge branch 'master' of scm.dev.troll.no:qt/qt-earth-team into ↵Shane Kearns2011-04-1168-251/+1523
| | |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | symbian-socket-engine Conflicts: src/s60installs/bwins/QtCoreu.def src/s60installs/bwins/QtGuiu.def src/s60installs/bwins/QtNetworku.def src/s60installs/eabi/QtCoreu.def src/s60installs/eabi/QtGuiu.def src/s60installs/eabi/QtNetworku.def src/s60installs/eabi/QtOpenVGu.def tests/auto/qabstractnetworkcache/tst_qabstractnetworkcache.cpp
| | * | | Implement support for sockets started before the event loopShane Kearns2011-04-081-1/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If there is no event loop when a socket notification is enabled, then invoke the method via a queued connection so that it is run again when the event loop is started. This covers sockets created and having an asynchronous API called before calling QCoreApplication::exec(). Reviewed-by: Markus Goetz
| | * | | QUdpSocket autotest updatesShane Kearns2011-04-081-23/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Start the default bearer, when Qt is built with bearer management 2. Allow server sockets to have IPv6 any addresses 3. Broadcasting test - broadcast on each valid broadcast address 4. Enable IPv6 tests on symbian 5. writeDatagram test - workaround symbian having a smaller recieve buffer for UDP packets than the maximum packet size it can send. 6. Add QEXPECT_FAIL for some multicast tests on symbian, the OS support for multicast is incomplete. 7. Choke the echo test, as the test server shuts down the echo service for 10 seconds when receiving packets too fast. 8. For manual testing, added the FORCE_SESSION macro to test behaviour of UDP sockets when they have an explicit network session associated Reviewed-by: Markus Goetz
| | * | | tst_qnetworkreply: skip ioGetFromBuiltinHttp test.Martin Petersson2011-04-061-0/+1
| | | | | | | | | | | | | | | | | | | | Reviewed-by: Markus Goetz
| | * | | tst_qtcpserver: Add a mapped v4 addr testMarkus Goetz2011-04-061-0/+35
| | | | | | | | | | | | | | | | | | | | Reviewed-by: Shane Kearns
| | * | | QHostInfo autotest fixes related to symbianShane Kearns2011-04-051-10/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. start default network at start of test (this makes the test faster and more reliable, as the network can be stopped automatically if we don't use a network session) 2. remove unnecessary ifdef from the ipv4 data 3. add new IPv6 test hosts to the ipv6 data 4. extend ipv6 timeout to match the ipv4 timeout 5. check error in LookupThread::run() to avoid test crashing on failure 6. extend timeout for multipleDifferentLookups (uncached DNS is SLOW) 7. enable IPv6 lookups on symbian statically (don't use the broken POSIX functions) Reviewed-by: Markus Goetz
| | * | | Add autotests for QHostInfo::abortHostLookupShane Kearns2011-04-051-0/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Test calling the abort from the same thread or from a different thread. The different thread is to check thread safety of the API. Reviewed-by: Markus Goetz
| | * | | Add test case for thread safety of the QHostInfo async APIShane Kearns2011-04-051-1/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing threadSafety test only tested calling the blocking API from multiple threads. As the asynchronous API may be implemented in a different way, it should be tested separately. Create 10 threads, each of which queues 10 async name lookups. Reviewed-by: Markus Goetz
| | * | | Fix ssl autotest .pro filesShane Kearns2011-03-293-19/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ReadUserData needed to avoid platsec warnings accessing cert store. Removed incorrect deployment from the two new on demand tests. Reviewed-by: Markus Goetz
| | * | | Remove 2 QSKIP from tst_qnetworkdiskcacheShane Kearns2011-03-291-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Skipped because of open C bug, but these tests are passing in N8 with symbian socket & file engines Reviewed-by: Markus Goetz
| | * | | Add bearer startup to qabstractnetworkcache autotestShane Kearns2011-03-291-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This avoids the test starting and stopping the WLAN for each test case Reviewed-by: Markus Goetz
| | * | | Make qhttpnetworkconnection autotest work with the new test serverShane Kearns2011-03-291-17/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Loosen requirements for generated error pages (these vary with exact version and locale of the web server). Don't care what the length is, but if a content-length header is sent then it should match the size of the error page data. (apache2 does send content-length for errors) Don't fail the gzip test if the server doesn't send a content-length header. That's a server bug rather than Qt. (apache2 doesn't send) Reviewed-by: Markus Goetz
| | * | | Symbian workaround for networkselftestShane Kearns2011-03-291-5/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The frox ftp proxy closes connections using TCP RST instead of a normal TCP FIN. On symbian, this causes the received but unacknowledged preceding packet to be discarded (the "221 Goodbye" ftp response). As QNAM and QFTP don't care about this, the network self test won't either. (only for symbian, as windows and unix TCP/IP stacks retain the unacknowledged packet in the receive queue) Reviewed-by: Markus Goetz
| | * | | Bearer support for autotestsShane Kearns2011-03-292-1/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Start default bearer when running network self test Fix typo in qnetworkreply test Reviewed-by: Markus Goetz
| | * | | Fix new http multipart test case on symbianShane Kearns2011-03-251-8/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new test added three reference data files required by the test, but these were not being included in the sis file. Reviewed-by: mread
| | * | | Merge remote branch 'earth/master' into symbian-socket-engineShane Kearns2011-03-25147-1910/+7752
| | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/network/access/qhttpnetworkconnectionchannel.cpp src/network/socket/qlocalsocket.cpp src/s60installs/bwins/QtCoreu.def src/s60installs/bwins/QtGuiu.def src/s60installs/bwins/QtTestu.def src/s60installs/eabi/QtCoreu.def src/s60installs/eabi/QtGuiu.def
| | * | | | Fix for tst_QEventLoop::processEventsExcludeSocketShane Kearns2011-03-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Depending on the OS scheduling, the TCP data sent and flushed may not have been looped back to trigger the socket's ready to read notification before the test called processEvents. This caused a failure on CI system windows 7. Added a short delay before processEvents to allow the OS to catch up. Reviewed-By: Markus Goetz
| | * | | | tst_qnetworkreply: Use proper Content-TypeMarkus Goetz2011-03-231-3/+16
| | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Peter Hartmann
| | * | | | Fix bugs in tst_qnetworkreplyShane Kearns2011-03-231-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It used a unix way to delete local servers. Changed this to the cross platform QLocalServer::removeServer API It reported XPASS on symbian due to SRCDIR being a relative path not absolute. (added a check for this, as SRCDIR could be relative on windows) Also fixed a couple of compiler warnings Reviewed-by: Martin Petersson
| | * | | | tst_qudpsocket - fix capabilitiesShane Kearns2011-03-173-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Trust Me
| | * | | | Make tst_QEventLoop::processEventsExcludeSocket stricterShane Kearns2011-03-172-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test was only checking that the socket event is not processed when excluded. I have added an additional test that a further call with socket events included results in the deferred socket event being processed. i.e. makes sure events are deferred to later and not lost. Also fixed capabilities of the autotest, so this test case can run. Reviewed-by: Markus Goetz
| | * | | | tst_qhostinfo: FixesMarkus Goetz2011-03-151-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Peter Hartmann
| | * | | | Enable IPv6 test in QNetworkInterface autotestShane Kearns2011-03-151-6/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | IPv6 test was skipped for symbian, now enabled it. Also start the default bearer before testing, so there are interfaces other than loopback available to test. Reviewed-by: Markus Goetz
| | * | | | Fix for server.listen getting IPv6 addressShane Kearns2011-03-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Markus Goetz
| | * | | | Fix capabilities in qtpcsocket autotestShane Kearns2011-03-153-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moved from the subdirs pro file to the executable pro files. Reviewed-by: Markus Goetz
| | * | | | tst_QNetworkReply::ioGetFromBuiltinHttp issuesShane Kearns2011-03-151-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The https:limited subtest was too slow and didn't fail in the expected place (it was expected to be too fast) Both limited test cases timed out when debug enabled in the socket engine, so the timeout is increased from 11->30 seconds Reviewed-by: Markus Goetz
| | * | | | Fixes for QTcpServer autotestShane Kearns2011-03-114-10/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set symbian capabilities in the two sub .pro files Enable IPv6 test on symbian Disable tests that use open C functions on socket descriptors When bearer management is enabled, start the network interface at start of the test. Reviewed-by: Markus Goetz
| | * | | | tst_qudpsocket - add a non localhost test caseShane Kearns2011-03-091-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The echo test case uses the UDP echo service on the qt-test-server Reviewed-by: Markus Goetz
| | * | | | tst_qtcpsocket - skip proxies for localhost testingShane Kearns2011-03-091-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no point to test the proxy setting for connections to localhost, because the proxy is bypassed anyway. Skipping running the same test case multiple times makes this test complete a bit faster. Reviewed-by: Markus Goetz
| | * | | | tst_qtcpsocket stabilisationShane Kearns2011-03-092-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Increased heap size to avoid OOM Increased timeouts in the timeoutConnect test, as these randomly fail at least in debug builds with 50ms (symbian threads have a 20ms timeslice for round robin scheduling of equal priority threads, so that could be related) Skip the setSocketDescriptor test on symbian, since native sockets are not ints, open c sockets are not supported, and we decided not to support RSocket adoption unless it's specifically requested. Reviewed-by: Markus Goetz
| | * | | | Reduce excessive timeout in tst_qtcpsocketShane Kearns2011-03-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Timeout of 5000 seconds (which was probably intended to be 5000ms) reduced to a more reasonable 60 seconds, to prevent the test from hanging in case of errors in the proxy server. Reviewed-by: Markus Goetz
| | * | | | Fix link error in qsocketnotifier testShane Kearns2011-03-091-4/+10
| | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Markus Goetz
| | * | | | Move some network tests from gui.pro to network.proShane Kearns2011-03-095-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These network tests have no dependency on the QtGui dll, so I have moved them to the network autotest group. In some cases this was not stated in the tests' .pro files. The gui autotest group still has a network test (qtcpsocket), but this has a dependency on QtGui for one test case (which uses QMessageBox) Reviewed-by: Markus Goetz
| | * | | | QTcpSocket autotest fixesShane Kearns2011-03-081-12/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. Don't crash if qt-test-server isn't found, fail instead 2. symbian: 200ms is too short for the timeout test when using proxies, extended to 1000ms 3. Don't crash when the disconnectWhileConnectingNoEventLoop fails used a QScopedPointer with custom cleanup to shutdown the thread tidily. 4. Fast fail for downloadBigFile test if the connection is lost before the download is complete. This uses the disconnected signal to exit the event loop early. Previously on this type of failure it took 10 minutes for the event loop to time out. Reviewed-by: Markus Goetz
| | * | | | Merge branch 'symbian-socket-engine' of ↵Shane Kearns2011-03-0818-123/+321
| | |\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | scm.dev.troll.no:qt/qt-symbian-network into symbian-socket-engine Conflicts: src/network/access/qnetworkaccessmanager.cpp tests/auto/qsslsocket/tst_qsslsocket.cpp
| | | * | | | Fix symbian test failures for qsslsocketShane Kearns2011-02-241-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Increased timeout on some unstable test cases. Added a Q_EXPECT_FAIL if we can't connect to a server which is inside firewall. Reviewed-by: Markus Goetz
| | | * | | | Fix qsslsocket test crashesShane Kearns2011-02-242-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert assertions to failure, increase heap size to allow creating 10MB buffers without std::bad_alloc exception or memory allocation error from openssl. Reviewed-by: Markus Goetz
| | | * | | | bugfix: QDir::entryList(Files|Readable) not listing writable filesShane Kearns2011-02-241-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mistake in the qfilesystemiterator_symbian implementation. Readable without Writable was thought to mean show only read-only files, but this isn't the expected behaviour of QDir[Iterator] Added an autotest, as this was only covered by ssl tests in the network layer. Reviewed-by: joao
| | | * | | | Fix ignored messages in platformsocketengine testShane Kearns2011-02-231-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: Markus Goetz