aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-02-06 01:00:11 +0100
committerFabian Kosmale <fabian.kosmale@qt.io>2020-02-06 08:41:57 +0100
commit7d86b35dc6833057cae86d9a70e8f2c598c68db5 (patch)
treec5b3e87bd0edef2d74bc16b5aba6cbb6b298cd81 /tests/auto/quick/qquickflickable/tst_qquickflickable.cpp
parent4975a33ba9aa357ba2bca93e292b1fbcfb34c24e (diff)
parent4e15f2135cdbefd9999a17d4e4fff5ea93679fac (diff)
Merge remote-tracking branch 'origin/5.14' into 5.15
Conflicts: .qmake.conf src/qml/types/qqmlbind.cpp src/quick/items/qquicklistview.cpp tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp Change-Id: Id6805c13256ad13d5651011e5dd09bba0ec02987
Diffstat (limited to 'tests/auto/quick/qquickflickable/tst_qquickflickable.cpp')
-rw-r--r--tests/auto/quick/qquickflickable/tst_qquickflickable.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp
index 5364530ca8..f3659290eb 100644
--- a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp
+++ b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp
@@ -205,6 +205,7 @@ private slots:
void overshoot_reentrant();
void synchronousDrag_data();
void synchronousDrag();
+ void visibleAreaBinding();
private:
void flickWithTouch(QQuickWindow *window, const QPoint &from, const QPoint &to);
@@ -2540,6 +2541,16 @@ void tst_qquickflickable::synchronousDrag()
QTest::touchEvent(window, touchDevice).release(0, p5, window);
}
+// QTBUG-81098: tests that a binding to visibleArea doesn't result
+// in a division-by-zero exception (when exceptions are enabled).
+void tst_qquickflickable::visibleAreaBinding()
+{
+ QScopedPointer<QQuickView> window(new QQuickView);
+ window->setSource(testFileUrl("visibleAreaBinding.qml"));
+ QTRY_COMPARE(window->status(), QQuickView::Ready);
+ // Shouldn't crash.
+}
+
QTEST_MAIN(tst_qquickflickable)
#include "tst_qquickflickable.moc"