summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-02-16 22:06:42 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-02-16 22:06:42 (GMT)
commitec3dc06b5fbf7ef37e0836992f6d7a3fd49c5891 (patch)
tree195c66ded290b2ebb4b2398c8967666eb0e7c2aa /tests/auto
parent95d3bd3fc993d7c8c1fe92960c617a3392d87f66 (diff)
parent9e5e97f3b5eaa9cda471be44a5c59b51561393b6 (diff)
downloadQt-ec3dc06b5fbf7ef37e0836992f6d7a3fd49c5891.zip
Qt-ec3dc06b5fbf7ef37e0836992f6d7a3fd49c5891.tar.gz
Qt-ec3dc06b5fbf7ef37e0836992f6d7a3fd49c5891.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-2: (26 commits) QLocalSocket::isValid on Windows must check for broken connection fix pipe handle leak in qlocalsocket_win.cpp GraphicsViewBenchmark: Run app in full screen mode on small desktops. Fix Thai text on Windows 7 Fix License headers. QTextCodec::codecForName. Insert in the cache in all cases. Prevented calling the pixmap filter implementations with null pixmaps. Make it possible to run benchmarks with the "-graphicssystem" switch. Add support for running the GraphicsViewBenchmark application manually. Bump version to 4.6.3. Fixed a GLX warning that occured with some Intel chipsets under X11. Fixed compile for maemo6. Cleanup QEglContext & EGLDisplays Moved 'hasAlpha' property from GL2 engine to GL paint device. Remove useless qDebug in QTextCodec autotest QTextCodec: Symbian has codec for UCS2, only fallback to UTF16 if UCS2 codec cannot be loaded Add caching to QTextCodec::codecForName and QTextCodec::codecForMib Add benchmark for QTextCodec Fix several bugs with GL texture cache Compile fix for OpenGL ES. ...
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/mediaobject/dummy/dummy.pro2
-rw-r--r--tests/auto/qgl/tst_qgl.cpp24
-rw-r--r--tests/auto/qtextcodec/tst_qtextcodec.cpp10
-rw-r--r--tests/auto/selftests/expected_cmptest.txt2
-rw-r--r--tests/auto/selftests/expected_crashes_3.txt2
-rw-r--r--tests/auto/selftests/expected_longstring.txt2
-rw-r--r--tests/auto/selftests/expected_maxwarnings.txt2
-rw-r--r--tests/auto/selftests/expected_skip.txt2
-rw-r--r--tests/auto/uic/baseline/config_fromuic3.ui.h2
9 files changed, 28 insertions, 20 deletions
diff --git a/tests/auto/mediaobject/dummy/dummy.pro b/tests/auto/mediaobject/dummy/dummy.pro
index 2f27c4a..cf1010e 100644
--- a/tests/auto/mediaobject/dummy/dummy.pro
+++ b/tests/auto/mediaobject/dummy/dummy.pro
@@ -1,7 +1,7 @@
TEMPLATE = lib
isEmpty(QT_MAJOR_VERSION) {
- VERSION=4.6.2
+ VERSION=4.6.3
} else {
VERSION=$${QT_MAJOR_VERSION}.$${QT_MINOR_VERSION}.$${QT_PATCH_VERSION}
}
diff --git a/tests/auto/qgl/tst_qgl.cpp b/tests/auto/qgl/tst_qgl.cpp
index d37d727..2983af3 100644
--- a/tests/auto/qgl/tst_qgl.cpp
+++ b/tests/auto/qgl/tst_qgl.cpp
@@ -57,6 +57,8 @@
#ifdef QT_BUILD_INTERNAL
#include <QtOpenGL/private/qgl_p.h>
#include <QtGui/private/qpixmapdata_p.h>
+#include <QtGui/private/qimage_p.h>
+#include <QtGui/private/qimagepixmapcleanuphooks_p.h>
#endif
//TESTED_CLASS=
@@ -1947,7 +1949,6 @@ void tst_QGL::qglContextDefaultBindTexture()
#ifdef QT_BUILD_INTERNAL
QGLWidget w;
w.makeCurrent();
-
QGLContext *ctx = const_cast<QGLContext*>(w.context());
QImage *boundImage = new QImage(256, 256, QImage::Format_RGB32);
@@ -1955,29 +1956,36 @@ void tst_QGL::qglContextDefaultBindTexture()
QPixmap *boundPixmap = new QPixmap(256, 256);
boundPixmap->fill(Qt::red);
- // Check that calling QGLContext::bindTexture with default args adds textures to cache
int startCacheItemCount = QGLTextureCache::instance()->size();
+
GLuint boundImageTextureId = ctx->bindTexture(*boundImage);
GLuint boundPixmapTextureId = ctx->bindTexture(*boundPixmap);
+
+ // Make sure the image & pixmap have been added to the cache:
QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount+2);
+ // Make sure the image & pixmap have the is_cached flag set:
+ QVERIFY(QImagePixmapCleanupHooks::isImageCached(*boundImage));
+ QVERIFY(QImagePixmapCleanupHooks::isPixmapCached(*boundPixmap));
+
// Make sure the texture IDs returned are valid:
QCOMPARE((bool)glIsTexture(boundImageTextureId), GL_TRUE);
QCOMPARE((bool)glIsTexture(boundPixmapTextureId), GL_TRUE);
- // Make sure the textures are still there after we delete the image/pixmap:
+ // Make sure the textures are still valid after we delete the image/pixmap:
+ // Also check that although the textures are left intact, the cache entries are removed:
delete boundImage;
boundImage = 0;
+ QCOMPARE((bool)glIsTexture(boundImageTextureId), GL_TRUE);
+ QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount+1);
delete boundPixmap;
boundPixmap = 0;
- QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount+2);
+ QCOMPARE((bool)glIsTexture(boundPixmapTextureId), GL_TRUE);
+ QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount);
- // Make sure the textures are deleted from the cache after calling QGLContext::deleteTexture()
+ // Finally, make sure QGLContext::deleteTexture deletes the texture IDs:
ctx->deleteTexture(boundImageTextureId);
ctx->deleteTexture(boundPixmapTextureId);
- QCOMPARE(QGLTextureCache::instance()->size(), startCacheItemCount);
-
- // Finally, make sure QGLContext::deleteTexture also deleted the texture IDs:
QCOMPARE((bool)glIsTexture(boundImageTextureId), GL_FALSE);
QCOMPARE((bool)glIsTexture(boundPixmapTextureId), GL_FALSE);
#endif
diff --git a/tests/auto/qtextcodec/tst_qtextcodec.cpp b/tests/auto/qtextcodec/tst_qtextcodec.cpp
index 65b0448..aa97e87 100644
--- a/tests/auto/qtextcodec/tst_qtextcodec.cpp
+++ b/tests/auto/qtextcodec/tst_qtextcodec.cpp
@@ -1795,12 +1795,12 @@ void tst_QTextCodec::utfHeaders()
QLatin1String ignoreReverseTestOn = (QSysInfo::ByteOrder == QSysInfo::BigEndian) ? QLatin1String(" le") : QLatin1String(" be");
QString rowName(QTest::currentDataTag());
- for (int i = 0; i < encoded.length(); ++i)
- qDebug() << hex << " " << (uint)(uchar)encoded.at(i);
+ /*for (int i = 0; i < encoded.length(); ++i)
+ qDebug() << hex << " " << (uint)(uchar)encoded.at(i);*/
if (toUnicode) {
QString result = codec->toUnicode(encoded.constData(), encoded.length(), &state);
- for (int i = 0; i < result.length(); ++i)
- qDebug() << hex << " " << (uint)result.at(i).unicode();
+ /*for (int i = 0; i < result.length(); ++i)
+ qDebug() << hex << " " << (uint)result.at(i).unicode();*/
QCOMPARE(result.length(), unicode.length());
QCOMPARE(result, unicode);
@@ -1939,7 +1939,7 @@ static int loadAndConvertMIB(int mib)
void tst_QTextCodec::threadSafety()
{
QThreadPool::globalInstance()->setMaxThreadCount(12);
-
+
QList<QByteArray> codecList = QTextCodec::availableCodecs();
QFuture<QByteArray> res = QtConcurrent::mapped(codecList, loadAndConvert);
diff --git a/tests/auto/selftests/expected_cmptest.txt b/tests/auto/selftests/expected_cmptest.txt
index 1b65adf..b7c5665 100644
--- a/tests/auto/selftests/expected_cmptest.txt
+++ b/tests/auto/selftests/expected_cmptest.txt
@@ -1,5 +1,5 @@
********* Start testing of tst_Cmptest *********
-Config: Using QTest library 4.6.2, Qt 4.6.2
+Config: Using QTest library 4.6.3, Qt 4.6.3
PASS : tst_Cmptest::initTestCase()
PASS : tst_Cmptest::compare_boolfuncs()
PASS : tst_Cmptest::compare_pointerfuncs()
diff --git a/tests/auto/selftests/expected_crashes_3.txt b/tests/auto/selftests/expected_crashes_3.txt
index aabe83d..71d79ca 100644
--- a/tests/auto/selftests/expected_crashes_3.txt
+++ b/tests/auto/selftests/expected_crashes_3.txt
@@ -1,5 +1,5 @@
********* Start testing of tst_Crashes *********
-Config: Using QTest library 4.6.2, Qt 4.6.2
+Config: Using QTest library 4.6.3, Qt 4.6.3
PASS : tst_Crashes::initTestCase()
QFATAL : tst_Crashes::crash() Received signal 11
FAIL! : tst_Crashes::crash() Received a fatal error.
diff --git a/tests/auto/selftests/expected_longstring.txt b/tests/auto/selftests/expected_longstring.txt
index 3fe237a..5d94e23 100644
--- a/tests/auto/selftests/expected_longstring.txt
+++ b/tests/auto/selftests/expected_longstring.txt
@@ -1,5 +1,5 @@
********* Start testing of tst_LongString *********
-Config: Using QTest library 4.6.2, Qt 4.6.2
+Config: Using QTest library 4.6.3, Qt 4.6.3
PASS : tst_LongString::initTestCase()
FAIL! : tst_LongString::failWithLongString() Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui.
diff --git a/tests/auto/selftests/expected_maxwarnings.txt b/tests/auto/selftests/expected_maxwarnings.txt
index 8bafeff..0da1799 100644
--- a/tests/auto/selftests/expected_maxwarnings.txt
+++ b/tests/auto/selftests/expected_maxwarnings.txt
@@ -1,5 +1,5 @@
********* Start testing of MaxWarnings *********
-Config: Using QTest library 4.6.2, Qt 4.6.2
+Config: Using QTest library 4.6.3, Qt 4.6.3
PASS : MaxWarnings::initTestCase()
QWARN : MaxWarnings::warn() 0
QWARN : MaxWarnings::warn() 1
diff --git a/tests/auto/selftests/expected_skip.txt b/tests/auto/selftests/expected_skip.txt
index c4ef92d..c603913 100644
--- a/tests/auto/selftests/expected_skip.txt
+++ b/tests/auto/selftests/expected_skip.txt
@@ -1,5 +1,5 @@
********* Start testing of tst_Skip *********
-Config: Using QTest library 4.6.2, Qt 4.6.2
+Config: Using QTest library 4.6.3, Qt 4.6.3
PASS : tst_Skip::initTestCase()
SKIP : tst_Skip::test() skipping all
Loc: [/home/rmcgover/depot/qt-git/mainline/tests/auto/selftests/skip/tst_skip.cpp(68)]
diff --git a/tests/auto/uic/baseline/config_fromuic3.ui.h b/tests/auto/uic/baseline/config_fromuic3.ui.h
index 6e22dc7..c77b303 100644
--- a/tests/auto/uic/baseline/config_fromuic3.ui.h
+++ b/tests/auto/uic/baseline/config_fromuic3.ui.h
@@ -45,7 +45,7 @@
** Form generated from reading UI file 'config_fromuic3.ui'
**
** Created: Thu Dec 17 12:48:42 2009
-** by: Qt User Interface Compiler version 4.6.2
+** by: Qt User Interface Compiler version 4.6.3
**
** WARNING! All changes made in this file will be lost when recompiling UI file!
********************************************************************************/