summaryrefslogtreecommitdiffstats
path: root/tests/auto
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix QTextBoundaryFinder usage cases in QAccessible2Konstantin Ritt2012-10-131-0/+1
| | | | | | | | | | | Make the implementation safer and closer to what http://www.linuxfoundation.org/collaborate/workgroups/accessibility/ia2/ia2_implementation_guide#boundaries requires us to do. Change-Id: I00af4697e52a9b6e7f5d7b3f403b29126fa1517b Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Mark QTreeView test as significant.Stephen Kelly2012-10-121-1/+0
| | | | | | | | | | | | I can't find any failures in the CI logs, as reported by the bug. Even if there is still an unstable test here, it is not appropriate to mark the entire test as insignificant, as that hides regressions in the entire class. Task-number: QTBUG-23638 Change-Id: I1aeaf6e725bf28e9ac03c9330a67e51241b9272b Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QTextBoundaryFinder: Fix handling of break opportunitiesKonstantin Ritt2012-10-121-191/+219
| | | | | | | | | | | | | | | | | Add BoundaryReason::BreakOpportunity flag that will be returned by the boundaryReasons() when the boundary finder is at the break opportunity position that might be not an item boundary. This is the same as (StartWord || EndWord) in Grapheme and Sentence modes; in Word and Line modes, BreakOpportunity flag might occur between the words or in between of Line boundaries (e.g. in conjunction with SoftHyphen flag). In other words, the text boundaries are always break opportunities, but not vice versa. StartWord and EndWord flags has been deprecated by new StartOfItem and EndOfItem flags which are not about the word boundaries only. In line breaking, StartOfItem and EndOfItem are set for the mandatory breaks only. Change-Id: I79bf297e2b988f5976f30cff0c8ca616385f6552 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Fix tst_QTextEdit::fullWidthSelection2() for shadow buildKonstantin Ritt2012-10-121-1/+1
| | | | | | | Search for the test data files in the test data directory, not in the current dir. Change-Id: I746e717bae575364102c1bb5c2888332d94c374f Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Fixed cosmetic line drawing where begin and end points are equal.Samuel Rødal2012-10-111-0/+21
| | | | | | | | | This case has typically required specific work-arounds in other rendering paths as well. Task-number: QTBUG-25153 Change-Id: I217e710a30222792ebca3bf297e438d944c32992 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Revert "Handle additional format ranges when itemizing."Pierre Rossi2012-10-102-112/+3
| | | | | | | | | | | This reverts commit 101d04681f4ceb7410681eae684534a206a9d90a. That change seems to have introduced a few regressions, and Creator hits an assertion that it introduced because it assumes the additionalFormats consists of well-formed ranges (QTCREATORBUG-7995). Change-Id: Ic4ae761e6e7f6df8a6b5ca565ceb250647420c15 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Move QValidator tests to QtGuiGiuseppe D'Angelo2012-10-1011-6/+6
| | | | | | | | Q*Validator classes are not in QtWidgets, so move them where they should stay. Change-Id: Ie6ea45a026e640fad131002bc9762c575235f3f4 Reviewed-by: David Faure <david.faure@kdab.com>
* Remove handleSynchronous* functions.Morten Johan Sorvig2012-10-101-3/+3
| | | | | | | | | | | | | | | | | | | | There are now two different ways to implement synchronous event processing. The platform plugins can choose which one to use. 1) flushWindowSystemEvents() Use to flush the event queue at one point, making preceding calls synchronous. 2) setSynchronousWindowsSystemEvents(bool enable) Makes all handle* functions synchronous, bypassing the event queue completely. Change-Id: I020b80c731fd13f855a377d7c91d06a4e39b6a0b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Samuel Rødal <samuel.rodal@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
* Fix a regression with regards to hfw behavior in QStackedWidgetJan Arve Saether2012-10-101-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a regression because we made QStackedWidget actually support heightForWidth in 4.8. This was done with change 4780f94e391b5e881497c5228661dead42c821fa. The problem was that heightForWidth was not calculated correctly because some of the pages were hidden. The hidden pages were actually not contributing to the hfw of the QStackedWidget at all. This again caused the QStackedWidget to change its heightForWidth() value when the current tab changed, which again could cause "jumps" in the UI when switching tabs (as demonstrated in the task). The problem was that the patch relied on calling QWidgetItem::heightForWidth(), and this function would return -1 if the widget was hidden. However, QWidget::heightForWidth() does not have this magic and returns the proper hfw value regardless of its visibility. One could argue about the correctness of this patch, but since QStackedLayout::sizeHint() disregards QWidgetItem::sizeHint() (it asks the widget directly), we do the same in QStackedLayoutHFW::heightForWidth() for consistency. In addition, QStackedLayout enforces that only widgets can be added to it, and you cannot add your own QLayoutItem subclasses to it: qWarning("QStackedLayout::addItem: Only widgets can be added"); Task-id: QTBUG-24758 Change-Id: I349cf8f4215e4581ea237ef773d53dcdf3db176b Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* tst_QMenuBar: remove QSKIP's -> omit whole test cases insteadJ-P Nurmi2012-10-101-46/+43
| | | | | | Change-Id: I2cf356c5790fd7f2b27a9032e2effacd098b3d05 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Caroline Chao <caroline.chao@digia.com>
* QTextBoundaryFinder: Introduce BoundaryReason::MandatoryBreak flagKonstantin Ritt2012-10-101-0/+37
| | | | | | | | | | that will be returned by boundaryReasons() when the boundary finder is at the line end position (CR, LF, NewLine Function, End of Text, etc.). The MandatoryBreak flag, if set, means the text should be wrapped at a given position. Change-Id: I32d4f570935d2e015bfc5f18915396a15f009fde Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Invalidate old QImage data if load()/loadFromData() has failedKonstantin Ritt2012-10-102-0/+170
| | | | | | | | | | This guarantees one will never get `!img.isNull()` after load()/loadFromData() has failed, even if the image was not null before. Apply the same fix to QPixmap and QPicture. Change-Id: Ida1ad6a6f0fc830df8e75ada0c163fc2d3360dea Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Mac: Bring back "Text boxes and list only" tab navigationGabriel de Dietrich2012-10-105-14/+10
| | | | | | | | | | | | | Added ThemeHint::TabAllWidgets as a mean to access that platform specific bool. The default implementation returns always true when querying QPlatformTheme::themeHint(). Several auto-tests had to be updated to reflect for qt_tab_all_widgets' type change. One XFAIL removed from tst_QApplication::focusChanged(). Task-number: QTBUG-24372 Change-Id: Ie1f0486c19898fe54c53aa4a27e378485075e512 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* tst_QApplication: Make sure the native style is being usedGabriel de Dietrich2012-10-101-0/+2
| | | | | | | | | | | The tst_QApplication::args() auto-test sets the style to windows style but there is no way to reset the style back to the native one. This makes tst_QApplication::focusChanged() fail on Mac in some cases, since not all the styles respond the same way to tab vs. strong focus changes. Change-Id: I91e39c1dd0fad4d90f3a13ab50a5e9758922ac28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Delete the QVariant ctors taking global Qt enum values.Stephen Kelly2012-10-101-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | They have unexpected results in Qt 5 (the Qt::GlobalColor one works as expected in Qt 4, but was removed in Qt 5): QVariant v = QVariant(Qt::red); qDebug() << v; // QVariant(int, 7) v = Qt::red; qDebug() << v; // QVariant(int, 7) The correct way is to use: QVariant v = QVariant::fromValue(QColor(Qt::red)); The deleted constructors are the ones for which there is a class with an implicit constructor taking the enum, and that class is a built-in metatype. QLocale::Language and QKeySequence::StandardKey would also fit the description, but I can't include the header for QKeySequence as it is in QtGui, and I don't want to include the qlocale header in qvariant.h. Putting a QLocale::Language is probably very uncommon anyway. The QTextFormat test is doing the wrong thing, but the result isn't being tested. Added new tests which fail before the patch. Change-Id: Ia38a0784990f4d40ff7457a86daf58aabd4964eb Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Scale icons returned by QIcon::fromTheme.David Sansome2012-10-101-0/+6
| | | | | | | | | | | | | | | | | The icon engine behind icons that are loaded from QIcon::fromTheme does not scale any pixmaps that it returns. When using an icon theme with an incomplete set of icons (for example, only a "128x128" folder), QIcon::pixmap will always return 128x128 pixmaps even if you ask for one of size 22x22. This is contrary to the QIcon::pixmap documentation that says "The pixmap might be smaller than requested, but never larger." This patch uses the same code that is in the main QIcon class in the PixmapEntry QIconLoaderEngineEntry to scale pixmaps if they are too big. Change-Id: Ic25a3628ac82cfb899574245f658490a2dd49d54 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Change QDateTime::addSecs() and QDateTime::secsTo() to use qint64.Jon Severinsson2012-10-101-2/+2
| | | | | | | | | | addMSecs() / msecsTo() have always used qint64, and when QDate was changed to use a 64-bit julian day, QDateTime::addDays() and QDateTime::daysTo() was changed to use qint64 in order to support the full extended range, but addSecs() and secsTo() seems to have been forgotten. Change-Id: I3acc35ee2bcc9f353650eb42f97d428f706b2db6 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Update the Unicode Data and Algorithms up to Unicode 6.2Konstantin Ritt2012-10-096-325/+829
| | | | | | | | | | | | | Version 6.2 of the Unicode Standard is a special release dedicated to the early publication of the newly encoded Turkish lira sign. In addition, there are some significant changes to the Unicode algorithms for text segmentation and line breaking to improve breaking for emoji symbols. For more details, see http://www.unicode.org/versions/Unicode6.2.0/ Change-Id: I21cfd4f307e41b41a19d36cce87f7a44c2661bc2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* tst_qfiledialog: fixed typo causing semi-random completer() failureRohan McGovern2012-10-091-1/+1
| | | | | | | | | | | | | | completer_data() was attempting to find the first folder which did not begin with a '.' character under QDir::root() for usage during the test. However, a typo caused it to find the first folder even if it _did_ begin with a '.'; unless the first folder returned by entryList() was ".", in which case no folder would be found. Change-Id: Ie95f1add797973d06a8d5f2fa32935366a008de5 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Removed the "tst_QVector::outOfMemory" test.Christian Strømme2012-10-081-148/+0
| | | | | | | | | | | The test is useless as we assert if the requested size exceeds a certain limit. We could, as an alternative, throw an exception, but in the end it's the caller's responsibility to ensure that the requested size is a sane value. Task-number: QTBUG-27285 Change-Id: I738950a6a2b51671a54e4d25c7e4c3ac0d7f63b8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Stabilize test qmenu::pushButtonPopulateOnAboutToShow().Friedemann Kleint2012-10-081-19/+32
| | | | | | | | Do not leave an allocated menu in member lastMenu behind that interferes with the consecutive QTBUG7907_submenus_autoselect(). Change-Id: I80fc9de9ca63367264f642023a244c1d7d8ada7f Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
* Handle additional format ranges when itemizing.Pierre Rossi2012-10-082-3/+112
| | | | | | | | | | | | | | This is useful when the additional formats are used on a text layout using a raw font. It can also come in handy for input methods operating on a QTextDocument. We now consider all format range edges to generate the associated items. The capitalization can be overridden via the additionnal formats mechanism. Adds an autotest that checks that this works with font capitalization. Change-Id: I782d2c48d05b0dfbad480a9ca77198465292b358 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* Fix Windows: QStandardPath::findExecutable() to check suffixes.Friedemann Kleint2012-10-081-26/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | Append the Windows executables suffixes from the PATHEXT environment variable. The previous code had a bug since the 'break' statement bailed out of the inner loop only. Factor search code out into a separate functions, avoiding repeated invocations of list.constEnd() and variable assignments in the old code. Add a static function that is called on Unix and on Windows for executable names with a suffix. Call another function applying a candidate list of suffixes in case an executable name without a suffix is passed. Lower case the extensions from PATHEXT, streamline code. Split up the test, add a _data() slot for clarity. Task-number: QTBUG-27457 Change-Id: I2bf34de52aeadddd3b937ad1e22191c3c850fd26 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* QSqlQuery::value string overloadThiago A. Correa2012-10-081-0/+1
| | | | | | | | | | Introduce value overload to take field name as a parameter. This allows for terser application code that avoids explicit calls to QSqlRecord::value(). Change-Id: I02b6712cd5ec41633b902714315b5716c17d1a9b Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Use jom in tst_qmake.Friedemann Kleint2012-10-081-1/+7
| | | | | | | | | | Speed up compiling the tests. Task-number: 26023 Change-Id: Ib5e872cc6cde09ac90f426a8f6e7cfea509d02e2 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Increase tst_qmake more time on Windows.Friedemann Kleint2012-10-081-0/+2
| | | | | | | | The test compiles examples, which takes a long time. Task-number: 26023 Change-Id: If794b046aa07737f3076aace8d585dc44027cc6b Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* QSqlTableModel::selectRow(): don't expand cache if there is no changeMark Brand2012-10-052-2/+21
| | | | | | | | Test added. Change-Id: Ibd72ef2aeee482abbd22991573460e55dc577457 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: David Faure (fixes for KDE) <faure@kde.org>
* QSqlTableModel: record(row) must use virtual data()Mark Brand2012-10-051-0/+41
| | | | | | | | | | | | | | Commit fbf010a26617b3986e9a76bd9c004403aebfcdc2 introduced a version of record(row) that includes the generated flags, but it neglected to populate the values using virtual data() as QSqlQueryModel correctly does. Test included lest we forget again. Change-Id: I49d0f8f87cd0c5078aa6a0e8373b2cffc01f2387 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QSqlTableModel: restore use of virtual setData() in setRecord()Mark Brand2012-10-051-9/+48
| | | | | | | | | | | | | | | | setRecord() should use setData() as intended so that reimplementations of setData() in subclasses will be respected. Commit 11bd543d901f67f79db3f5b5dfaa626c6e8faa45 failed to consider this. Test added which should prevent this mistake being repeated. Change-Id: Ia2d930cd42b5a27521bb389edb1b07fb1bf0fa36 Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* QSqlTableModel: don't cache unchanged value in setData()Mark Brand2012-10-051-0/+8
| | | | | | | | | | | | | | | | | | | | | | This is good for performance in terms of avoiding unnecessary database activity and keeping the cache smaller. Detail: This change was not included in the big refactoring of QSqlTM. The idea was that the model shouldn't second guess the intention of the application and maybe the application wants to cause a submit. It was a marginal consideration. Now I think it's clear that our interest in not unnecessarily expanding the cache outweighs that. In addition, applications can now call selectRow() if they worry that the database values for the row have changed and want to set a value back again. Test added. Change-Id: I63814dcb63a96c6ba1c8cc227807725a954a0b68 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: David Faure <david.faure@kdab.com>
* QSqlTableModel: fix segfault when overriding selectRow()Mark Brand2012-10-051-0/+49
| | | | | | | | | | | | | | | | | The STL-style iteration over the cache in submitAll() assumed the iterator would remain valid until reaching cache.end(). This failed to consider that virtual selectRow() might be overridden so that it removes rows from the cache. For example, it might call select() which would empty the cache. The new approach checks at each iteration whether the row is still in the cache. Using foreach here is justified by its fitness for purpose and readability. New test included. Change-Id: Idee8807ede239c3ba56ff1604574c49f47385ad2 Reviewed-by: David Faure (fixes for KDE) <faure@kde.org>
* test: Remove QSKIP from tst_QToolButton::triggered()Sergio Ahumada2012-10-041-4/+0
| | | | | | | | This test actually passes on Mac OS X, so removing the QSKIP Task-number: QTBUG-24374 Change-Id: I0b761ca9c30afc9d511e9962ee1c0958b863b374 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* Fix segfault when delegates change properties on editors.Stephen Kelly2012-10-041-0/+56
| | | | | | | | | | | The solution is similar to that in b84e180263d0da3d1e6967fcf759225a778ea6ea which affected QSortFilterProxyModel. Task-number: QTBUG-25370 Change-Id: I6bbb9d9786bcb2c9fa8027ab8a7cc13664784b8d Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* CMake: Improve QT5_GET_MOC_FLAGS macroStephen Kelly2012-10-044-0/+127
| | | | | | | | | | | | We need to handle CMAKE_INCLUDE_CURRENT_DIR for include directories. Otherwise generated files located in the current binary directory are not found as expected. e.g. *.json file as meta data for Qt5's plugins generated at build time. Change-Id: I14ae1e7013f9d8b485aa990d50db4a03ca4f4b81 Reviewed-by: Yuchen Deng <loaden@gmail.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* tst_QLocale: remove QSKIP, wrap Q_OS_MAC/Q_OS_WINSergio Ahumada2012-10-041-5/+8
| | | | | Change-Id: I44755379561b98e43dd19c8c01b40349be203e14 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Remove #if 0 usage in QElapsedTimer autotest.Leonard Lee2012-10-041-20/+3
| | | | | | | | | Given QElapsedTimer t1, t2 variable, the t1-t2, t1+1000 (add 1 second) operations not supported. Task-number: QTBUG-22446 Change-Id: Idd87f778c212831aa7f92242452538d113c9cfcf Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix #if 0 usage in collections autotest.Leonard Lee2012-10-041-22/+20
| | | | | | | | Removed inappropriate use of #if 0 in collections autotest. Task-number: QTBUG-22471 Change-Id: Ibf4e5fae8e671ebfd0dc5734875fcc8879b330af Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove unused function.Frederik Gladhorn2012-10-031-11/+0
| | | | | Change-Id: Ie8eecf7e4a7475ac84a66b6055149ce92d019785 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Fix for integer overflow in QString::replaceChristian Strømme2012-10-031-2/+0
| | | | | | | Task-number: QTBUG-22967 Change-Id: I604e6a725d46eab4c4369ebb54e8c9ea1350f492 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix QTextBoundaryFinder assignment operatorKonstantin Ritt2012-10-031-0/+25
| | | | | | | for the case when the boundary finder is assigned to an invalid one. Change-Id: I5b60984ff3fd99972fcae21895684bd83b012780 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
* Overhaul a little the QUrl error reporting.Thiago Macieira2012-10-021-11/+16
| | | | | | | | | | | | | | | | | | | | | | Keep the original QString that triggered the parsing error, instead of just one QChar. This provides more powerful error messages, like: Invalid IPv6 address; source was "http://[:::]"; scheme = "http", host = "" (QUrl cannot keep invalid hostnames) Invalid port or port number out of range; source was "http://example.com:abc"; scheme = "http", host = "example.com" (QUrl cannot keep a non-numeric port number) Invalid path (character '%' not permitted); source was "foo:/path%?"; scheme = "foo", path = "/path%25%1F" (the tolerant parser runs first, so the faulty component is fixed) This stores the error state in a special structure which is not allocated under normal conditions, keeping the memory consumption down. On 32-bit systems, QUrlPrivate does not increase in size; on 64-bit systems, it grows by 8 bytes. Change-Id: I93d798d43401dfeb9fca7b6eed7ea758da10136b Reviewed-by: David Faure <faure@kde.org>
* Update some error messages in QUrl::errorString()Thiago Macieira2012-10-021-8/+12
| | | | | | | | | Make both invalid hostname messages start with "Invalid hostname". And split the empty port error from the invalid port one. Change-Id: I870d1ed6fb07ec494f553871a37ed167141ffc06 Reviewed-by: David Faure <faure@kde.org> Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
* Remove the annoying qWarning when QUrl::setPort is out of rangeThiago Macieira2012-10-021-3/+0
| | | | | | | | | | That's what we have QUrl::errorString() for. This will become evident especially now that QUrl::toString() / toEncoded() return empty if there are errors. Change-Id: I64a84e9c6ee57c0fc38cc0c58f5286ddc1248d1f Reviewed-by: Shane Kearns <shane.kearns@accenture.com> Reviewed-by: David Faure <faure@kde.org>
* Make QUrl::errorString() usable for QtTest output in invalid URLsThiago Macieira2012-10-024-8/+8
| | | | | | | | | If an URL is invalid, let's indicate that in the test output. To be helpful, let's make QUrl::errorString() include the component form of the URL. Change-Id: Iaafe16973ded79c7ea688fbb23808d91253e8c14 Reviewed-by: David Faure <faure@kde.org>
* Make QUrl::toString() / toEncoded() return empty for invalid URLsThiago Macieira2012-10-021-4/+43
| | | | | Change-Id: I6ebb4ad2901a9bacb09fb81082202f37ebbc2e97 Reviewed-by: David Faure <faure@kde.org>
* Add two compound URL invalidity cases for isValid()Thiago Macieira2012-10-021-14/+32
| | | | | | | | | | | | | | These two errors can only happen if one calls setPath() explicitly. They cannot happen for parsed URLs, which is why they are only caught with isValid(). It's not possible to set the error condition in setPath() either because they depend on the presence / absence of the authority and scheme. Also update all the unit tests that set a path not starting with a slash and were just "freeloaders" on the previous behaviour. Change-Id: Ice58cd4589a850452d7573a5b19667bbab2fb43e Reviewed-by: David Faure <faure@kde.org>
* QProcess.tests: adding test for channel forwardingThomas Hartmann2012-10-024-0/+89
| | | | | | | | | | This tests QProcess::setProcessChannelMode(). The tests verifies if testForwarding really forwards the output of testProcessEcho (spawned by testForwarding). Change-Id: Ifc4164569256aeaeab0edef42116986272362c01 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Rename createLocalFile to createNativeFile & deprecate createLocalFileAndy Shaw2012-10-024-1/+44
| | | | | | | | | | | | | | | | | | As it was confusing to use the term local file when referring to a file that was accessible using native APIs and not just a file that was on a hard disk somewhere already the function name has been changed. By renaming it to createNativeFile we keep it consistant with QFileInfo which has an isNativeFile() function too. Test also added. Task-number: QTBUG-3169 Change-Id: I410e7ed28133d68fd312c6c0faf3f7191460d7ce Reviewed-by: João Abecasis <joao@abecasis.name> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* typo fixed in tst_QLocalSocket::verifyListenWithDescriptor_dataJoerg Bornemann2012-10-021-1/+1
| | | | | Change-Id: Ic549c8fa7f98052a45b391d6a9bfef3d2557c709 Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
* QWinOverlappedIoNotifier test for multiple I/O operations addedJoerg Bornemann2012-10-021-20/+102
| | | | | | | | | | | tst_QWinOverlappedIoNotifier::multipleOperations starts asynchronous read and write operations on the same named pipe handle. The received notifications must contain the right byte count and OVERLAPPED pointer corresponding to the I/O operation. Change-Id: I6f3fa5cf3ca6d62fcb9bc7073d28611fcfa7d98a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>