diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-03-30 02:35:46 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-03-30 02:35:46 (GMT) |
commit | 9a23f377b38a2e65da9b67982d7ca770dbcc16b0 (patch) | |
tree | 3a9a2eb64855fcab3cdf911a71955bb9282ab62a /tests | |
parent | a716c176c5a89c5dd0e3f0a9b6738d8a217ee6b9 (diff) | |
parent | 84413a25bc025f099a075387fb6ab8449d9ef217 (diff) | |
download | Qt-9a23f377b38a2e65da9b67982d7ca770dbcc16b0.zip Qt-9a23f377b38a2e65da9b67982d7ca770dbcc16b0.tar.gz Qt-9a23f377b38a2e65da9b67982d7ca770dbcc16b0.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Return correct boundaries reasons from QTextBoundaryFinder.
GridView jumps to beginning of list when resized
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp | 35 | ||||
-rw-r--r-- | tests/auto/qtextboundaryfinder/tst_qtextboundaryfinder.cpp | 6 |
2 files changed, 18 insertions, 23 deletions
diff --git a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp index 45f38a4..a35a2c9 100644 --- a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp +++ b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp @@ -604,10 +604,8 @@ void tst_qdeclarativetextinput::moveCursorSelection_data() << standard[2] << 13 << 6 << QDeclarativeTextInput::SelectWords << 6 << 13 << false; QTest::newRow("Hello<(, world!)>|words") << standard[2] << 5 << 13 << QDeclarativeTextInput::SelectWords << 5 << 13 << true; - // Fails due to an issue with QTextBoundaryFinder and punctuation at the end of strings. - // QTBUG-11365 - // QTest::newRow("world<(!)>|words") - // << standard[2] << 12 << 13 << QDeclarativeTextInput::SelectWords << 12 << 13 << true; + QTest::newRow("world<(!)>|words") + << standard[2] << 12 << 13 << QDeclarativeTextInput::SelectWords << 12 << 13 << true; QTest::newRow("world!<()>)|words") << standard[2] << 13 << 13 << QDeclarativeTextInput::SelectWords << 13 << 13 << true; QTest::newRow("world<()>!)|words") @@ -653,16 +651,15 @@ void tst_qdeclarativetextinput::moveCursorSelection_data() QTest::newRow(" <s(pac)ey> text |words") << standard[4] << 1 << 4 << QDeclarativeTextInput::SelectWords << 1 << 7 << true; QTest::newRow(" spacey <t(ex)t> |words") - << standard[4] << 11 << 13 << QDeclarativeTextInput::SelectWords << 10 << 14 << false; // Should be reversible. QTBUG-11365 + << standard[4] << 11 << 13 << QDeclarativeTextInput::SelectWords << 10 << 14 << true; QTest::newRow("<( )>spacey text |words|ltr") << standard[4] << 0 << 1 << QDeclarativeTextInput::SelectWords << 0 << 1 << false; QTest::newRow("<( )spacey> text |words|rtl") << standard[4] << 1 << 0 << QDeclarativeTextInput::SelectWords << 0 << 7 << false; QTest::newRow("spacey <text( )>|words|ltr") << standard[4] << 14 << 15 << QDeclarativeTextInput::SelectWords << 10 << 15 << false; -// QTBUG-11365 -// QTest::newRow("spacey text<( )>|words|rtl") -// << standard[4] << 15 << 14 << QDeclarativeTextInput::SelectWords << 14 << 15 << false; + QTest::newRow("spacey text<( )>|words|rtl") + << standard[4] << 15 << 14 << QDeclarativeTextInput::SelectWords << 14 << 15 << false; QTest::newRow("<()> spacey text |words") << standard[4] << 0 << 0 << QDeclarativeTextInput::SelectWords << 0 << 0 << false; QTest::newRow(" spacey text <()>|words") @@ -857,23 +854,21 @@ void tst_qdeclarativetextinput::moveCursorSelectionSequence_data() << 15 << 12 << 15 << 10 << 15 << 15 << 15; -// QTBUG-11365 -// QTest::newRow(" spacey <te(xt{^ )>}|rtl") -// << standard[4] -// << 15 << 12 << 14 -// << 10 << 15 -// << 14 << 15; + QTest::newRow(" spacey <te(xt{^ )>}|rtl") + << standard[4] + << 15 << 12 << 14 + << 10 << 15 + << 14 << 15; QTest::newRow(" spacey {<te(x^t} )>|ltr") << standard[4] << 12 << 15 << 13 << 10 << 15 << 10 << 14; -// QTBUG-11365 -// QTest::newRow(" spacey {<te(xt^} )>|ltr") -// << standard[4] -// << 12 << 15 << 14 -// << 10 << 15 -// << 10 << 14; + QTest::newRow(" spacey {<te(xt^} )>|ltr") + << standard[4] + << 12 << 15 << 14 + << 10 << 15 + << 10 << 14; } void tst_qdeclarativetextinput::moveCursorSelectionSequence() diff --git a/tests/auto/qtextboundaryfinder/tst_qtextboundaryfinder.cpp b/tests/auto/qtextboundaryfinder/tst_qtextboundaryfinder.cpp index 6157004..8003c44 100644 --- a/tests/auto/qtextboundaryfinder/tst_qtextboundaryfinder.cpp +++ b/tests/auto/qtextboundaryfinder/tst_qtextboundaryfinder.cpp @@ -257,10 +257,10 @@ void tst_QTextBoundaryFinder::sentenceBoundaries() void tst_QTextBoundaryFinder::isAtWordStart() { - QString txt("The quick brown fox jumped over $the lazy. dog "); + QString txt("The quick brown fox jumped over $the lazy. dog I win!"); QList<int> start, end; - start << 0 << 4 << 10 << 16 << 20 << 27 << 32 << 33 << 37 << 41 << 43; - end << 3 << 9 << 15 << 19 << 26 << 31 << 33 << 36 << 41 << 42 << 46; + start << 0 << 4 << 10 << 16 << 20 << 27 << 32 << 33 << 37 << 41 << 43 << 48 << 50 << 53; + end << 3 << 9 << 15 << 19 << 26 << 31 << 33 << 36 << 41 << 42 << 46 << 49 << 53 << 54; QTextBoundaryFinder finder(QTextBoundaryFinder::Word, txt); for(int i=0; i < txt.length(); ++i) { finder.setPosition(i); |