diff options
author | Adrian Yanes <ext-adrian.yanes@nokia.com> | 2010-12-03 17:04:32 +0000 |
---|---|---|
committer | Adrian Yanes <ext-adrian.yanes@nokia.com> | 2010-12-03 17:04:32 +0000 |
commit | bde96d358a9edd5969781770e44f20be3693468a (patch) | |
tree | aa660ffd30f504f8fc9cbf8b3e32675013bcf6b9 /tests | |
parent | 5356556411c2b176aec4ab24ca7407b4e585d64f (diff) |
Revert "Changes: new test cases for MTheme, MStyleSheetParser, MScalableImage"
Details: working at sb, failing at device :_(
This reverts commit 8139d3856ead6a6c9348ac124eb6c007c2488403.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/ft_mscalableimage/ft_mscalableimage.cpp | 8 | ||||
-rw-r--r-- | tests/ft_mscalableimage/ft_mscalableimage.h | 2 | ||||
-rw-r--r-- | tests/ft_mstylesheetparser/ft_mstylesheetparser.cpp | 20 | ||||
-rw-r--r-- | tests/ft_mstylesheetparser/ft_mstylesheetparser.h | 1 | ||||
-rw-r--r-- | tests/ut_mtheme/ut_mtheme.cpp | 53 | ||||
-rw-r--r-- | tests/ut_mtheme/ut_mtheme.h | 3 |
6 files changed, 0 insertions, 87 deletions
diff --git a/tests/ft_mscalableimage/ft_mscalableimage.cpp b/tests/ft_mscalableimage/ft_mscalableimage.cpp index 8fdb2c86..96ce3ca8 100644 --- a/tests/ft_mscalableimage/ft_mscalableimage.cpp +++ b/tests/ft_mscalableimage/ft_mscalableimage.cpp @@ -196,13 +196,5 @@ void Ft_MScalableImage::verifyResult(const QImage& image, const QSize& paintSize QCOMPARE(isImageBlockColor(image, QRect(BLOCK_SIZE, BLOCK_SIZE, center_width, center_height), COLOR_CENTER), true); } -void Ft_MScalableImage::testEnableOptimizedRendering() -{ - /* the method does nothing, not even storing the value. These calls are just - to cheat the coverage tools */ - m_subject->enableOptimizedRendering(true); - m_subject->enableOptimizedRendering(false); -} - QTEST_APPLESS_MAIN(Ft_MScalableImage) diff --git a/tests/ft_mscalableimage/ft_mscalableimage.h b/tests/ft_mscalableimage/ft_mscalableimage.h index 1ea8419a..53bba5bb 100644 --- a/tests/ft_mscalableimage/ft_mscalableimage.h +++ b/tests/ft_mscalableimage/ft_mscalableimage.h @@ -40,8 +40,6 @@ private slots: void test_draw_scalable9(); void test_draw_scalable1(); - void testEnableOptimizedRendering(); - private: void verifyResult(const QImage& image, const QSize& paintSize); class MScalableImage *m_subject; diff --git a/tests/ft_mstylesheetparser/ft_mstylesheetparser.cpp b/tests/ft_mstylesheetparser/ft_mstylesheetparser.cpp index d7d555d5..cfc5faec 100644 --- a/tests/ft_mstylesheetparser/ft_mstylesheetparser.cpp +++ b/tests/ft_mstylesheetparser/ft_mstylesheetparser.cpp @@ -723,24 +723,4 @@ void Ft_MStyleSheetParser::test_binary_speed() qDebug() << "Total reading time:" << TOTAL_TIME << "microseconds (" << TOTAL_TIME / 1000000.0 << "seconds)"; } -void Ft_MStyleSheetParser::test_set_binary_file_directory() -{ - MStyleSheetParser parser; - QString binaryPath = qApp->applicationDirPath(); - QString cssPath = qApp->applicationDirPath() + QDir::separator() + "ft_mstylesheetparser_test.css"; - - parser.setBinaryFileGenerationEnabled(true); - parser.setBinaryFileDirectory(binaryPath); - parser.load(cssPath); - - QString binaryFilename = cssPath; - binaryFilename.replace(QLatin1Char('_'), "__"); - binaryFilename.replace(QLatin1Char('/'), "_."); - - /* Check that binary file was created in the right dir */ - QVERIFY(QFile::exists(binaryPath + QDir::separator() + binaryFilename)); - - /* remove the created file */ - QFile::remove(binaryPath + QDir::separator() + binaryFilename); -} QTEST_APPLESS_MAIN(Ft_MStyleSheetParser) diff --git a/tests/ft_mstylesheetparser/ft_mstylesheetparser.h b/tests/ft_mstylesheetparser/ft_mstylesheetparser.h index 4685d9f8..f85b964e 100644 --- a/tests/ft_mstylesheetparser/ft_mstylesheetparser.h +++ b/tests/ft_mstylesheetparser/ft_mstylesheetparser.h @@ -47,7 +47,6 @@ private slots: void test_binary_equality(); void test_parser_speed(); void test_binary_speed(); - void test_set_binary_file_directory(); /*void test_inheritance(); void test_objectnames(); diff --git a/tests/ut_mtheme/ut_mtheme.cpp b/tests/ut_mtheme/ut_mtheme.cpp index 1783d4d4..ffd21774 100644 --- a/tests/ut_mtheme/ut_mtheme.cpp +++ b/tests/ut_mtheme/ut_mtheme.cpp @@ -450,57 +450,4 @@ void Ut_MTheme::waitForPendingThemeRequests() } } -void Ut_MTheme::testAddPixmapDirectory() { - - const QPixmap *invalid; - const QPixmap *valid; - QString pixmapId="ut_mtheme"; - QSize validPixmapSize(20,20); - QSize invalidPixmapSize(50,50); - - /* Request a pixmap not available. This will return the 50x50 red pixmap */ - invalid = m_theme->pixmap(pixmapId, validPixmapSize); - QVERIFY(invalid->size() == invalidPixmapSize); - m_theme->releasePixmap(invalid); - m_theme->cleanupGarbage(); - - /* Add current directory so the pixmap can be found */ - m_theme->addPixmapDirectory(qApp->applicationDirPath()); - - /* And then request the pixmap again, which will return the right one */ - valid = m_theme->pixmap(pixmapId, validPixmapSize); - QVERIFY(valid->size() == validPixmapSize); - m_theme->releasePixmap(valid); - m_theme->cleanupGarbage(); - QCOMPARE(cachedIconCount(), 0); - QVERIFY(!isIconCached(pixmapId, QSize())); -} - -void Ut_MTheme::testClearPixmapDirectories() { - - const QPixmap *invalid; - const QPixmap *valid; - QSize validPixmapSize(20,20); - QSize invalidPixmapSize(50,50); - QString pixmapId="ut_mtheme"; - - /* Add current dir to the list */ - m_theme->addPixmapDirectory(qApp->applicationDirPath()); - - /* Request a pixmap available */ - valid = m_theme->pixmap(pixmapId, validPixmapSize); - QVERIFY(valid->size() == validPixmapSize); - m_theme->releasePixmap(valid); - m_theme->cleanupGarbage(); - - /* clear pixmap directories */ - m_theme->clearPixmapDirectories(); - - /* And request it again to get the invalid pixmap */ - invalid = m_theme->pixmap(pixmapId, validPixmapSize); - QVERIFY(invalid->size() == invalidPixmapSize); - m_theme->releasePixmap(invalid); - m_theme->cleanupGarbage(); -} - QTEST_APPLESS_MAIN(Ut_MTheme) diff --git a/tests/ut_mtheme/ut_mtheme.h b/tests/ut_mtheme/ut_mtheme.h index 8faf819c..ca22fd89 100644 --- a/tests/ut_mtheme/ut_mtheme.h +++ b/tests/ut_mtheme/ut_mtheme.h @@ -52,9 +52,6 @@ private slots: void testScalableImage(); void testView(); - void testAddPixmapDirectory(); - void testClearPixmapDirectories(); - private: /** * @return True, if the given icon has been cached in the theme daemon. |