aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/quick/qquicktext/tst_qquicktext.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/auto/quick/qquicktext/tst_qquicktext.cpp b/tests/auto/quick/qquicktext/tst_qquicktext.cpp
index d6534e504c..6f37a6a01f 100644
--- a/tests/auto/quick/qquicktext/tst_qquicktext.cpp
+++ b/tests/auto/quick/qquicktext/tst_qquicktext.cpp
@@ -3484,6 +3484,22 @@ void tst_qquicktext::imgSize_data()
<< qint64(0x10000)
<< qint64(0x10000)
<< QQuickText::RichText;
+ QTest::newRow("out-of-bounds (styled text)") << QStringLiteral("images/starfish_2.png")
+ << (qint64(INT_MAX) + 1)
+ << (qint64(INT_MAX) + 1)
+ << QQuickText::StyledText;
+ QTest::newRow("out-of-bounds (rich text)") << QStringLiteral("images/starfish_2.png")
+ << (qint64(INT_MAX) + 1)
+ << (qint64(INT_MAX) + 1)
+ << QQuickText::RichText;
+ QTest::newRow("negative out-of-bounds (styled text)") << QStringLiteral("images/starfish_2.png")
+ << (qint64(INT_MIN) - 1)
+ << (qint64(INT_MIN) - 1)
+ << QQuickText::StyledText;
+ QTest::newRow("negative out-of-bounds (rich text)") << QStringLiteral("images/starfish_2.png")
+ << (qint64(INT_MIN) - 1)
+ << (qint64(INT_MIN) - 1)
+ << QQuickText::RichText;
QTest::newRow("large non-existent (styled text)") << QStringLiteral("a")
<< qint64(0x7FFFFF)
<< qint64(0x7FFFFF)