summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2022-05-20 11:44:36 +0200
committerEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>2022-05-20 13:14:01 +0200
commit4fe9374589aa36129c8275c2c207bd09b7df0ba5 (patch)
tree9ea5ae3b56f474c1b353d96449321a6d36ccad24 /tests/auto/widgets
parent2dc82c21774a84234f471610ce2635d0cc2070ea (diff)
Fix crash in tst_qquicktext::implicitSize
This reverts commit 1e938c348b936328fafbcaae4c0c7d91003143e5 and bb2f4d08d9d138e4f70d6d6db46e24e34500becc. bb2f4d08d9d causes the crash, but 1e938c348b93 amends it, so this reverts both. When the cause of the crash has been determined and mitigated, the patches can be recreated. Fixes: QTBUG-103719 Change-Id: Ifc36b3771a96f6c85387a5306a0402d4c508d006 Reviewed-by: David Faure <david.faure@kdab.com>
Diffstat (limited to 'tests/auto/widgets')
-rw-r--r--tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp b/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
index 72d2cc7aa7..bc533df48a 100644
--- a/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
+++ b/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
@@ -1194,9 +1194,8 @@ void tst_QTextEdit::undoRedoShouldRepositionTextEditCursor()
void tst_QTextEdit::lineWrapModes()
{
ed->setLineWrapMode(QTextEdit::NoWrap);
- // NoWrap at the same time as having all lines that are all left aligned means we optimize to
- // only layout once. The effect is that the width is always -1
- QCOMPARE(ed->document()->pageSize().width(), qreal(-1));
+ // NoWrap at the same time as having all lines that are all left aligned means we optimize to only layout once. The effect is that the width is always 0
+ QCOMPARE(ed->document()->pageSize().width(), qreal(0));
QTextCursor cursor = QTextCursor(ed->document());
cursor.insertText(QString("A simple line"));