From aa291c55b4dd2d647723fa32e9062a4d150d92ef Mon Sep 17 00:00:00 2001 From: Michael Goddard Date: Mon, 26 Mar 2012 13:35:44 +1000 Subject: Make this unit test a bit more robust for qreal changes. It's not just ARM that has qreal == float (and sometimes not even then) Change-Id: Ic2fa890afd9f926c455442d04dc84e57dffe7787 Reviewed-by: Jonas Rabbe --- tests/auto/unit/qvideosurfaceformat/tst_qvideosurfaceformat.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tests/auto/unit/qvideosurfaceformat/tst_qvideosurfaceformat.cpp b/tests/auto/unit/qvideosurfaceformat/tst_qvideosurfaceformat.cpp index 016ad651b..ea613952c 100644 --- a/tests/auto/unit/qvideosurfaceformat/tst_qvideosurfaceformat.cpp +++ b/tests/auto/unit/qvideosurfaceformat/tst_qvideosurfaceformat.cpp @@ -996,11 +996,7 @@ void tst_QVideoSurfaceFormat::debugOperator() " frameWidth = QVariant(int, %6) \n" " viewport = QVariant(QRect, QRect(0,1 800x600) ) \n" " scanLineDirection = QVariant(QVideoSurfaceFormat::Direction, ) \n" -#if defined(Q_PROCESSOR_ARM) // from qglobal.h - " frameRate = QVariant(float, %7) \n" -#else - " frameRate = QVariant(double, %7) \n" -#endif + " frameRate = QVariant(%7, %8) \n" " pixelAspectRatio = QVariant(QSize, QSize(320, 200) ) \n" " sizeHint = QVariant(QSize, QSize(1280, 600) ) \n" " yCbCrColorSpace = QVariant(QVideoSurfaceFormat::YCbCrColorSpace, ) ") @@ -1010,6 +1006,7 @@ void tst_QVideoSurfaceFormat::debugOperator() .arg(frameSize.width()) .arg(frameSize.height()) .arg(frameSize.width()) + .arg(sizeof(qreal) == sizeof(double) ? "double" : "float") .arg(frameRate); QVideoSurfaceFormat vsf(frameSize, format, QAbstractVideoBuffer::GLTextureHandle); -- cgit v1.2.3