diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-01-28 16:50:34 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-01-28 16:50:34 (GMT) |
commit | 9d636095403f5abecbdff8ffffe658f35ff10001 (patch) | |
tree | fda62cb14f16f3a8b92b5cd41dc972cac4a19ef6 /tests/auto/qimagereader | |
parent | c69b74008c72b7e2da5ff4bc57112b89d0a36d7d (diff) | |
parent | b383ff766764f4d0d9644ca06bfb049d62bdcf2f (diff) | |
download | Qt-9d636095403f5abecbdff8ffffe658f35ff10001.zip Qt-9d636095403f5abecbdff8ffffe658f35ff10001.tar.gz Qt-9d636095403f5abecbdff8ffffe658f35ff10001.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:
Fix a regression: icons with slightly wrong ICO header did not load.
Fixed an endless loop if printing web pages.
don't build unneeded QtDesigner parts on Windows CE
Better support for user-generated binary shaders
Diffstat (limited to 'tests/auto/qimagereader')
-rw-r--r-- | tests/auto/qimagereader/baseline/35floppy.ico | bin | 4286 -> 0 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/35floppy.png | bin | 0 -> 329 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/connect.png | bin | 0 -> 12943 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/kde_favicon.ico | bin | 1150 -> 0 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/kde_favicon.png | bin | 0 -> 514 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/semitransparent.ico | bin | 9662 -> 0 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/baseline/semitransparent.png | bin | 0 -> 545 bytes | |||
-rw-r--r-- | tests/auto/qimagereader/tst_qimagereader.cpp | 13 |
8 files changed, 10 insertions, 3 deletions
diff --git a/tests/auto/qimagereader/baseline/35floppy.ico b/tests/auto/qimagereader/baseline/35floppy.ico Binary files differdeleted file mode 100644 index 59fd37e..0000000 --- a/tests/auto/qimagereader/baseline/35floppy.ico +++ /dev/null diff --git a/tests/auto/qimagereader/baseline/35floppy.png b/tests/auto/qimagereader/baseline/35floppy.png Binary files differnew file mode 100644 index 0000000..56b9b44 --- /dev/null +++ b/tests/auto/qimagereader/baseline/35floppy.png diff --git a/tests/auto/qimagereader/baseline/connect.png b/tests/auto/qimagereader/baseline/connect.png Binary files differnew file mode 100644 index 0000000..9544bb9 --- /dev/null +++ b/tests/auto/qimagereader/baseline/connect.png diff --git a/tests/auto/qimagereader/baseline/kde_favicon.ico b/tests/auto/qimagereader/baseline/kde_favicon.ico Binary files differdeleted file mode 100644 index 15bcdbb..0000000 --- a/tests/auto/qimagereader/baseline/kde_favicon.ico +++ /dev/null diff --git a/tests/auto/qimagereader/baseline/kde_favicon.png b/tests/auto/qimagereader/baseline/kde_favicon.png Binary files differnew file mode 100644 index 0000000..e19287b --- /dev/null +++ b/tests/auto/qimagereader/baseline/kde_favicon.png diff --git a/tests/auto/qimagereader/baseline/semitransparent.ico b/tests/auto/qimagereader/baseline/semitransparent.ico Binary files differdeleted file mode 100644 index dd23de9..0000000 --- a/tests/auto/qimagereader/baseline/semitransparent.ico +++ /dev/null diff --git a/tests/auto/qimagereader/baseline/semitransparent.png b/tests/auto/qimagereader/baseline/semitransparent.png Binary files differnew file mode 100644 index 0000000..a3ad780 --- /dev/null +++ b/tests/auto/qimagereader/baseline/semitransparent.png diff --git a/tests/auto/qimagereader/tst_qimagereader.cpp b/tests/auto/qimagereader/tst_qimagereader.cpp index 72c5c8b..e7cfe68 100644 --- a/tests/auto/qimagereader/tst_qimagereader.cpp +++ b/tests/auto/qimagereader/tst_qimagereader.cpp @@ -1633,7 +1633,8 @@ void tst_QImageReader::pixelCompareWithBaseline_data() QTest::newRow("floppy (16px,32px - 16 colors)") << "35floppy.ico"; QTest::newRow("semitransparent") << "semitransparent.ico"; - QTest::newRow("slightlybroken") << "kde_favicon.ico"; + QTest::newRow("slightlybrokenBMPHeader") << "kde_favicon.ico"; + QTest::newRow("sightlybrokenIconHeader") << "connect.ico"; } void tst_QImageReader::pixelCompareWithBaseline() @@ -1641,14 +1642,20 @@ void tst_QImageReader::pixelCompareWithBaseline() QFETCH(QString, fileName); QImage icoImg; + const QString inputFileName(QString::fromAscii("images/%1").arg(fileName)); + QFileInfo fi(inputFileName); + // might fail if the plugin does not exist, which is ok. - if (icoImg.load(QString::fromAscii("images/%1").arg(fileName))) { - QString baselineFileName = QString::fromAscii("baseline/%1").arg(fileName); + if (icoImg.load(inputFileName)) { + icoImg = icoImg.convertToFormat(QImage::Format_ARGB32_Premultiplied); + const QString baselineFileName(QString::fromAscii("baseline/%1.png").arg(fi.baseName())); #if 0 icoImg.save(baselineFileName); #else QImage baseImg; QVERIFY(baseImg.load(baselineFileName)); + baseImg = baseImg.convertToFormat(QImage::Format_ARGB32_Premultiplied); + QCOMPARE(int(baseImg.format()), int(icoImg.format())); QCOMPARE(baseImg, icoImg); #endif } |