diff options
author | J-P Nurmi <jpnurmi@digia.com> | 2013-03-18 16:33:06 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-03-18 22:32:15 +0100 |
commit | 36e6632fa363152e1a0d42e53a0e5ada09092324 (patch) | |
tree | aedbcf75b1b5337fa0de24191cd90c30a7989e23 | |
parent | 4111a676f1073e2f29de2c042785a941dbfb9458 (diff) |
Tests: stabilize tst_QDockWidget on small screens
The test has been recently failing in CI. The problem was easy to
reproduce in a virtual machine by resizing the window of the virtual
machine small enough. This change makes sure that the requested size
hint is significantly smaller than the desktop size, to avoid the
window manager stepping in and limiting the window size.
Change-Id: Id8ce63b2b88cbed964e0330633c5d2e1dc33598c
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
-rw-r--r-- | tests/auto/widgets/widgets/qdockwidget/tst_qdockwidget.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/widgets/widgets/qdockwidget/tst_qdockwidget.cpp b/tests/auto/widgets/widgets/qdockwidget/tst_qdockwidget.cpp index 92b16ac155..6ab7cb4491 100644 --- a/tests/auto/widgets/widgets/qdockwidget/tst_qdockwidget.cpp +++ b/tests/auto/widgets/widgets/qdockwidget/tst_qdockwidget.cpp @@ -735,7 +735,7 @@ void tst_QDockWidget::task169808_setFloating() QSize sizeHint() const { const QRect& deskRect = qApp->desktop()->availableGeometry(); - return QSize(qMin(300, deskRect.width()), 300); + return QSize(qMin(300, deskRect.width() / 2), qMin(300, deskRect.height() / 2)); } QSize minimumSizeHint() const |