From d9597782202b2be117874330ceee95040c7365cb Mon Sep 17 00:00:00 2001 From: Ariya Hidayat Date: Tue, 15 Sep 2009 12:14:03 +0200 Subject: Don't do pixel tests in QGraphicsEffect on other than 32-bit display. Reviewed-by: Paul Olav Tvete --- tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp index d5205cd..ba3783b 100644 --- a/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp +++ b/tests/auto/qgraphicseffect/tst_qgraphicseffect.cpp @@ -41,6 +41,7 @@ #include +#include #include #include #include @@ -369,6 +370,11 @@ void tst_QGraphicsEffect::opacity() void tst_QGraphicsEffect::grayscale() { + if (qApp->desktop()->depth() < 24) { + QSKIP("Test only works on 32 bit displays", SkipAll); + return; + } + QGraphicsScene scene(0, 0, 100, 100); QGraphicsRectItem *item = scene.addRect(0, 0, 50, 50); @@ -412,6 +418,11 @@ void tst_QGraphicsEffect::grayscale() void tst_QGraphicsEffect::colorize() { + if (qApp->desktop()->depth() < 24) { + QSKIP("Test only works on 32 bit displays", SkipAll); + return; + } + QGraphicsScene scene(0, 0, 100, 100); QGraphicsRectItem *item = scene.addRect(0, 0, 50, 50); -- cgit v0.12