| Line | Source | Count |
| 1 | | - |
| 2 | | - |
| 3 | | - |
| 4 | | - |
| 5 | | - |
| 6 | | - |
| 7 | | - |
| 8 | | - |
| 9 | | - |
| 10 | | - |
| 11 | | - |
| 12 | | - |
| 13 | | - |
| 14 | | - |
| 15 | | - |
| 16 | | - |
| 17 | | - |
| 18 | | - |
| 19 | | - |
| 20 | | - |
| 21 | | - |
| 22 | | - |
| 23 | | - |
| 24 | | - |
| 25 | | - |
| 26 | | - |
| 27 | | - |
| 28 | | - |
| 29 | | - |
| 30 | | - |
| 31 | | - |
| 32 | | - |
| 33 | | - |
| 34 | | - |
| 35 | | - |
| 36 | | - |
| 37 | | - |
| 38 | | - |
| 39 | | - |
| 40 | | - |
| 41 | #include "qmimeprovider_p.h" | - |
| 42 | | - |
| 43 | #ifndef QT_NO_MIMETYPE | - |
| 44 | | - |
| 45 | #include "qmimetypeparser_p.h" | - |
| 46 | #include <qstandardpaths.h> | - |
| 47 | #include "qmimemagicrulematcher_p.h" | - |
| 48 | | - |
| 49 | #include <QXmlStreamReader> | - |
| 50 | #include <QDir> | - |
| 51 | #include <QFile> | - |
| 52 | #include <QByteArrayMatcher> | - |
| 53 | #include <QDebug> | - |
| 54 | #include <QDateTime> | - |
| 55 | #include <QtEndian> | - |
| 56 | | - |
| 57 | static void initResources() | - |
| 58 | { | - |
| 59 | Q_INIT_RESOURCE(mimetypes); | - |
| 60 | }executed 2 times by 2 tests: end of blockExecuted by:- tst_QMimeDatabase
- tst_qmimetype
| 2 |
| 61 | | - |
| 62 | QT_BEGIN_NAMESPACE | - |
| 63 | | - |
| 64 | static QString fallbackParent(const QString &mimeTypeName) | - |
| 65 | { | - |
| 66 | const QString myGroup = mimeTypeName.left(mimeTypeName.indexOf(QLatin1Char('/'))); | - |
| 67 | | - |
| 68 | if (myGroup == QLatin1String("text") && mimeTypeName != QLatin1String("text/plain"))| TRUE | evaluated 28 times by 1 test | | FALSE | evaluated 40 times by 1 test |
| TRUE | evaluated 8 times by 1 test | | FALSE | evaluated 20 times by 1 test |
| 8-40 |
| 69 | return QLatin1String("text/plain");executed 8 times by 1 test: return QLatin1String("text/plain"); | 8 |
| 70 | | - |
| 71 | if (myGroup != QLatin1String("inode") &&| TRUE | evaluated 52 times by 1 test | | FALSE | evaluated 8 times by 1 test |
| 8-52 |
| 72 | | - |
| 73 | myGroup != QLatin1String("all") && myGroup != QLatin1String("fonts") && myGroup != QLatin1String("print") && myGroup != QLatin1String("uri")| TRUE | evaluated 52 times by 1 test | | FALSE | never evaluated |
| TRUE | evaluated 52 times by 1 test | | FALSE | never evaluated |
| TRUE | evaluated 52 times by 1 test | | FALSE | never evaluated |
| TRUE | evaluated 52 times by 1 test | | FALSE | never evaluated |
| 0-52 |
| 74 | && mimeTypeName != QLatin1String("application/octet-stream")) {| TRUE | evaluated 36 times by 1 test | | FALSE | evaluated 16 times by 1 test |
| 16-36 |
| 75 | return QLatin1String("application/octet-stream");executed 36 times by 1 test: return QLatin1String("application/octet-stream"); | 36 |
| 76 | } | - |
| 77 | return QString();executed 24 times by 1 test: return QString(); | 24 |
| 78 | } | - |
| 79 | | - |
| 80 | QMimeProviderBase::QMimeProviderBase(QMimeDatabasePrivate *db) | - |
| 81 | : m_db(db) | - |
| 82 | { | - |
| 83 | }executed 27 times by 24 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
| 27 |
| 84 | | - |
| 85 | Q_CORE_EXPORT int qmime_secondsBetweenChecks = 5; | - |
| 86 | | - |
| 87 | bool QMimeProviderBase::shouldCheck() | - |
| 88 | { | - |
| 89 | if (m_lastCheck.isValid() && m_lastCheck.elapsed() < qmime_secondsBetweenChecks * 1000)| TRUE | evaluated 16372 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 25 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| TRUE | evaluated 16245 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 127 times by 4 testsEvaluated by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
|
| 25-16372 |
| 90 | return false;executed 16245 times by 23 tests: return false;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 16245 |
| 91 | m_lastCheck.start(); | - |
| 92 | return true;executed 152 times by 24 tests: return true;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
| 152 |
| 93 | } | - |
| 94 | | - |
| 95 | QMimeBinaryProvider::QMimeBinaryProvider(QMimeDatabasePrivate *db) | - |
| 96 | : QMimeProviderBase(db), m_mimetypeListLoaded(false) | - |
| 97 | { | - |
| 98 | }executed 25 times by 24 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
| 25 |
| 99 | | - |
| 100 | #if defined(Q_OS_UNIX) && !defined(Q_OS_INTEGRITY) | - |
| 101 | #define QT_USE_MMAP | - |
| 102 | #endif | - |
| 103 | | - |
| 104 | struct QMimeBinaryProvider::CacheFile | - |
| 105 | { | - |
| 106 | CacheFile(const QString &fileName); | - |
| 107 | ~CacheFile(); | - |
| 108 | | - |
| 109 | bool isValid() const { return m_valid; }executed 24 times by 23 tests: return m_valid;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 24 |
| 110 | inline quint16 getUint16(int offset) const | - |
| 111 | { | - |
| 112 | return qFromBigEndian(*reinterpret_cast<quint16 *>(data + offset));executed 54 times by 23 tests: return qFromBigEndian(*reinterpret_cast<quint16 *>(data + offset));Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 54 |
| 113 | } | - |
| 114 | inline quint32 getUint32(int offset) const | - |
| 115 | { | - |
| 116 | return qFromBigEndian(*reinterpret_cast<quint32 *>(data + offset));executed 316408 times by 23 tests: return qFromBigEndian(*reinterpret_cast<quint32 *>(data + offset));Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 316408 |
| 117 | } | - |
| 118 | inline const char *getCharStar(int offset) const | - |
| 119 | { | - |
| 120 | return reinterpret_cast<const char *>(data + offset);executed 143248 times by 23 tests: return reinterpret_cast<const char *>(data + offset);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 143248 |
| 121 | } | - |
| 122 | bool load(); | - |
| 123 | bool reload(); | - |
| 124 | | - |
| 125 | QFile file; | - |
| 126 | uchar *data; | - |
| 127 | QDateTime m_mtime; | - |
| 128 | bool m_valid; | - |
| 129 | }; | - |
| 130 | | - |
| 131 | QMimeBinaryProvider::CacheFile::CacheFile(const QString &fileName) | - |
| 132 | : file(fileName), m_valid(false) | - |
| 133 | { | - |
| 134 | load(); | - |
| 135 | }executed 24 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 24 |
| 136 | | - |
| 137 | QMimeBinaryProvider::CacheFile::~CacheFile() | - |
| 138 | { | - |
| 139 | } | - |
| 140 | | - |
| 141 | bool QMimeBinaryProvider::CacheFile::load() | - |
| 142 | { | - |
| 143 | if (!file.open(QIODevice::ReadOnly))| TRUE | never evaluated | | FALSE | evaluated 27 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-27 |
| 144 | return false; never executed: return false; | 0 |
| 145 | data = file.map(0, file.size()); | - |
| 146 | if (data) {| TRUE | evaluated 27 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-27 |
| 147 | const int major = getUint16(0); | - |
| 148 | const int minor = getUint16(2); | - |
| 149 | m_valid = (major == 1 && minor >= 1 && minor <= 2);| TRUE | evaluated 27 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| TRUE | evaluated 27 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| TRUE | evaluated 27 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-27 |
| 150 | }executed 27 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 27 |
| 151 | m_mtime = QFileInfo(file).lastModified(); | - |
| 152 | return m_valid;executed 27 times by 23 tests: return m_valid;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 27 |
| 153 | } | - |
| 154 | | - |
| 155 | bool QMimeBinaryProvider::CacheFile::reload() | - |
| 156 | { | - |
| 157 | | - |
| 158 | m_valid = false; | - |
| 159 | if (file.isOpen()) {| TRUE | evaluated 3 times by 1 test | | FALSE | never evaluated |
| 0-3 |
| 160 | file.close(); | - |
| 161 | }executed 3 times by 1 test: end of block | 3 |
| 162 | data = 0; | - |
| 163 | return load();executed 3 times by 1 test: return load(); | 3 |
| 164 | } | - |
| 165 | | - |
| 166 | QMimeBinaryProvider::CacheFile *QMimeBinaryProvider::CacheFileList::findCacheFile(const QString &fileName) const | - |
| 167 | { | - |
| 168 | for (const_iterator it = begin(); it != end(); ++it) {| TRUE | evaluated 3 times by 1 test | | FALSE | evaluated 24 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 3-24 |
| 169 | if ((*it)->file.fileName() == fileName)| TRUE | evaluated 2 times by 1 test | | FALSE | evaluated 1 time by 1 test |
| 1-2 |
| 170 | return *it;executed 2 times by 1 test: return *it; | 2 |
| 171 | }executed 1 time by 1 test: end of block | 1 |
| 172 | return 0;executed 24 times by 23 tests: return 0;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 24 |
| 173 | } | - |
| 174 | | - |
| 175 | QMimeBinaryProvider::~QMimeBinaryProvider() | - |
| 176 | { | - |
| 177 | qDeleteAll(m_cacheFiles); | - |
| 178 | }executed 25 times by 25 tests: end of blockExecuted by:- tst_QMimeDatabase
- tst_languagechange - unknown status
- tst_qaccessibility - unknown status
- tst_qcalendarwidget - unknown status
- tst_qcombobox - unknown status
- tst_qcompleter - unknown status
- tst_qdatetimeedit - unknown status
- tst_qdebug - unknown status
- tst_qfiledialog - unknown status
- tst_qfiledialog2 - unknown status
- tst_qfileiconprovider - unknown status
- tst_qfilesystemmodel - unknown status
- tst_qfontcombobox - unknown status
- tst_qgraphicsproxywidget - unknown status
- tst_qgraphicswidget - unknown status
- tst_qguiapplication - unknown status
- tst_qguivariant - unknown status
- tst_qicon - unknown status
- tst_qmimedatabase-cache - unknown status
- tst_qmimetype
- tst_qprinter - unknown status
- tst_qsidebar - unknown status
- tst_qstyle - unknown status
- tst_qsystemtrayicon - unknown status
- tst_qtoolbutton - unknown status
| 25 |
| 179 | | - |
| 180 | | - |
| 181 | enum { | - |
| 182 | PosAliasListOffset = 4, | - |
| 183 | PosParentListOffset = 8, | - |
| 184 | PosLiteralListOffset = 12, | - |
| 185 | PosReverseSuffixTreeOffset = 16, | - |
| 186 | PosGlobListOffset = 20, | - |
| 187 | PosMagicListOffset = 24, | - |
| 188 | | - |
| 189 | PosIconsListOffset = 32, | - |
| 190 | PosGenericIconsListOffset = 36 | - |
| 191 | }; | - |
| 192 | | - |
| 193 | bool QMimeBinaryProvider::isValid() | - |
| 194 | { | - |
| 195 | #if defined(QT_USE_MMAP) | - |
| 196 | if (!qEnvironmentVariableIsEmpty("QT_NO_MIME_CACHE"))| TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 24 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| 1-24 |
| 197 | return false;executed 1 time by 1 test: return false; | 1 |
| 198 | | - |
| 199 | Q_ASSERT(m_cacheFiles.isEmpty()); | - |
| 200 | checkCache(); | - |
| 201 | | - |
| 202 | if (m_cacheFiles.count() > 1)| TRUE | never evaluated | | FALSE | evaluated 24 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| 0-24 |
| 203 | return true; never executed: return true; | 0 |
| 204 | if (m_cacheFiles.isEmpty())| TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 23 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 1-23 |
| 205 | return false;executed 1 time by 1 test: return false; | 1 |
| 206 | | - |
| 207 | | - |
| 208 | const QString foundFile = m_cacheFiles.constFirst()->file.fileName(); | - |
| 209 | const QString localCacheFile = QStandardPaths::writableLocation(QStandardPaths::GenericDataLocation) + QLatin1String("/mime/mime.cache"); | - |
| 210 | | - |
| 211 | return foundFile != localCacheFile;executed 23 times by 23 tests: return foundFile != localCacheFile;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 23 |
| 212 | #else | - |
| 213 | return false; | - |
| 214 | #endif | - |
| 215 | } | - |
| 216 | | - |
| 217 | bool QMimeBinaryProvider::CacheFileList::checkCacheChanged() | - |
| 218 | { | - |
| 219 | bool somethingChanged = false; | - |
| 220 | QMutableListIterator<CacheFile *> it(*this); | - |
| 221 | while (it.hasNext()) {| TRUE | evaluated 97 times by 4 testsEvaluated by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
| | FALSE | evaluated 96 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| 96-97 |
| 222 | CacheFile *cacheFile = it.next(); | - |
| 223 | QFileInfo fileInfo(cacheFile->file); | - |
| 224 | if (!fileInfo.exists()) { | TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 96 times by 4 testsEvaluated by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
|
| 1-96 |
| 225 | delete cacheFile; | - |
| 226 | it.remove(); | - |
| 227 | somethingChanged = true; | - |
| 228 | } else if (fileInfo.lastModified() > cacheFile->m_mtime) {executed 1 time by 1 test: end of block | TRUE | evaluated 3 times by 1 test | | FALSE | evaluated 93 times by 4 testsEvaluated by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
|
| 1-93 |
| 229 | if (!cacheFile->reload()) {| TRUE | never evaluated | | FALSE | evaluated 3 times by 1 test |
| 0-3 |
| 230 | delete cacheFile; | - |
| 231 | it.remove(); | - |
| 232 | } never executed: end of block | 0 |
| 233 | somethingChanged = true; | - |
| 234 | }executed 3 times by 1 test: end of block | 3 |
| 235 | }executed 97 times by 4 tests: end of blockExecuted by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
| 97 |
| 236 | return somethingChanged;executed 96 times by 24 tests: return somethingChanged;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
| 96 |
| 237 | } | - |
| 238 | | - |
| 239 | void QMimeBinaryProvider::checkCache() | - |
| 240 | { | - |
| 241 | if (!shouldCheck())| TRUE | evaluated 11745 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 96 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| 96-11745 |
| 242 | return;executed 11745 times by 23 tests: return;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 11745 |
| 243 | | - |
| 244 | | - |
| 245 | if (m_cacheFiles.checkCacheChanged())| TRUE | evaluated 4 times by 1 test | | FALSE | evaluated 92 times by 24 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
|
| 4-92 |
| 246 | m_mimetypeListLoaded = false;executed 4 times by 1 test: m_mimetypeListLoaded = false; | 4 |
| 247 | | - |
| 248 | | - |
| 249 | const QStringList cacheFileNames = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QLatin1String("mime/mime.cache")); | - |
| 250 | if (cacheFileNames != m_cacheFileNames) {| TRUE | evaluated 25 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 71 times by 5 testsEvaluated by:- tst_QFileDialog2
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QMimeDatabase
- tst_qmimetype
|
| 25-71 |
| 251 | for (const QString &cacheFileName : cacheFileNames) { | - |
| 252 | CacheFile *cacheFile = m_cacheFiles.findCacheFile(cacheFileName); | - |
| 253 | if (!cacheFile) {| TRUE | evaluated 24 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2 times by 1 test |
| 2-24 |
| 254 | | - |
| 255 | cacheFile = new CacheFile(cacheFileName); | - |
| 256 | if (cacheFile->isValid()) | TRUE | evaluated 24 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-24 |
| 257 | m_cacheFiles.append(cacheFile);executed 24 times by 23 tests: m_cacheFiles.append(cacheFile);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 24 |
| 258 | else | - |
| 259 | delete cacheFile; never executed: delete cacheFile; | 0 |
| 260 | } | - |
| 261 | }executed 26 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 26 |
| 262 | m_cacheFileNames = cacheFileNames; | - |
| 263 | m_mimetypeListLoaded = false; | - |
| 264 | }executed 25 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 25 |
| 265 | }executed 96 times by 24 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
- tst_qmimetype
| 96 |
| 266 | | - |
| 267 | static QMimeType mimeTypeForNameUnchecked(const QString &name) | - |
| 268 | { | - |
| 269 | QMimeTypePrivate data; | - |
| 270 | data.name = name; | - |
| 271 | | - |
| 272 | | - |
| 273 | | - |
| 274 | | - |
| 275 | return QMimeType(data);executed 7911 times by 23 tests: return QMimeType(data);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 7911 |
| 276 | } | - |
| 277 | | - |
| 278 | QMimeType QMimeBinaryProvider::mimeTypeForName(const QString &name) | - |
| 279 | { | - |
| 280 | checkCache(); | - |
| 281 | if (!m_mimetypeListLoaded)| TRUE | evaluated 28 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 4553 times by 20 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_languageChange
|
| 28-4553 |
| 282 | loadMimeTypeList();executed 28 times by 23 tests: loadMimeTypeList();Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 28 |
| 283 | if (!m_mimetypeNames.contains(name))| TRUE | evaluated 8 times by 1 test | | FALSE | evaluated 4573 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 8-4573 |
| 284 | return QMimeType(); executed 8 times by 1 test: return QMimeType(); | 8 |
| 285 | return mimeTypeForNameUnchecked(name);executed 4573 times by 23 tests: return mimeTypeForNameUnchecked(name);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 4573 |
| 286 | } | - |
| 287 | | - |
| 288 | QStringList QMimeBinaryProvider::findByFileName(const QString &fileName, QString *foundSuffix) | - |
| 289 | { | - |
| 290 | checkCache(); | - |
| 291 | if (fileName.isEmpty())| TRUE | evaluated 2 times by 1 test | | FALSE | evaluated 2523 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2-2523 |
| 292 | return QStringList();executed 2 times by 1 test: return QStringList(); | 2 |
| 293 | const QString lowerFileName = fileName.toLower(); | - |
| 294 | QMimeGlobMatchResult result; | - |
| 295 | | - |
| 296 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 297 | matchGlobList(result, cacheFile, cacheFile->getUint32(PosLiteralListOffset), fileName); | - |
| 298 | matchGlobList(result, cacheFile, cacheFile->getUint32(PosGlobListOffset), fileName); | - |
| 299 | const int reverseSuffixTreeOffset = cacheFile->getUint32(PosReverseSuffixTreeOffset); | - |
| 300 | const int numRoots = cacheFile->getUint32(reverseSuffixTreeOffset); | - |
| 301 | const int firstRootOffset = cacheFile->getUint32(reverseSuffixTreeOffset + 4); | - |
| 302 | matchSuffixTree(result, cacheFile, numRoots, firstRootOffset, lowerFileName, fileName.length() - 1, false); | - |
| 303 | if (result.m_matchingMimeTypes.isEmpty())| TRUE | evaluated 34 times by 3 testsEvaluated by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| | FALSE | evaluated 2492 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 34-2492 |
| 304 | matchSuffixTree(result, cacheFile, numRoots, firstRootOffset, fileName, fileName.length() - 1, true);executed 34 times by 3 tests: matchSuffixTree(result, cacheFile, numRoots, firstRootOffset, fileName, fileName.length() - 1, true);Executed by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| 34 |
| 305 | }executed 2526 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2526 |
| 306 | if (foundSuffix)| TRUE | evaluated 8 times by 1 test | | FALSE | evaluated 2515 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 8-2515 |
| 307 | *foundSuffix = result.m_foundSuffix;executed 8 times by 1 test: *foundSuffix = result.m_foundSuffix; | 8 |
| 308 | return result.m_matchingMimeTypes;executed 2523 times by 22 tests: return result.m_matchingMimeTypes;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2523 |
| 309 | } | - |
| 310 | | - |
| 311 | void QMimeBinaryProvider::matchGlobList(QMimeGlobMatchResult &result, CacheFile *cacheFile, int off, const QString &fileName) | - |
| 312 | { | - |
| 313 | const int numGlobs = cacheFile->getUint32(off); | - |
| 314 | | - |
| 315 | for (int i = 0; i < numGlobs; ++i) {| TRUE | evaluated 45324 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 5052 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 5052-45324 |
| 316 | const int globOffset = cacheFile->getUint32(off + 4 + 12 * i); | - |
| 317 | const int mimeTypeOffset = cacheFile->getUint32(off + 4 + 12 * i + 4); | - |
| 318 | const int flagsAndWeight = cacheFile->getUint32(off + 4 + 12 * i + 8); | - |
| 319 | const int weight = flagsAndWeight & 0xff; | - |
| 320 | const bool caseSensitive = flagsAndWeight & 0x100; | - |
| 321 | const Qt::CaseSensitivity qtCaseSensitive = caseSensitive ? Qt::CaseSensitive : Qt::CaseInsensitive;| TRUE | evaluated 2523 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 42801 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2523-42801 |
| 322 | const QString pattern = QLatin1String(cacheFile->getCharStar(globOffset)); | - |
| 323 | | - |
| 324 | const char *mimeType = cacheFile->getCharStar(mimeTypeOffset); | - |
| 325 | | - |
| 326 | QMimeGlobPattern glob(pattern, QString() , weight, qtCaseSensitive); | - |
| 327 | | - |
| 328 | | - |
| 329 | if (glob.matchFileName(fileName))| TRUE | evaluated 16 times by 1 test | | FALSE | evaluated 45308 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 16-45308 |
| 330 | result.addMatch(QLatin1String(mimeType), weight, pattern);executed 16 times by 1 test: result.addMatch(QLatin1String(mimeType), weight, pattern); | 16 |
| 331 | }executed 45324 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 45324 |
| 332 | }executed 5052 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 5052 |
| 333 | | - |
| 334 | bool QMimeBinaryProvider::matchSuffixTree(QMimeGlobMatchResult &result, QMimeBinaryProvider::CacheFile *cacheFile, int numEntries, int firstOffset, const QString &fileName, int charPos, bool caseSensitiveCheck) | - |
| 335 | { | - |
| 336 | QChar fileChar = fileName[charPos]; | - |
| 337 | int min = 0; | - |
| 338 | int max = numEntries - 1; | - |
| 339 | while (min <= max) {| TRUE | evaluated 18328 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2554 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2554-18328 |
| 340 | const int mid = (min + max) / 2; | - |
| 341 | const int off = firstOffset + 12 * mid; | - |
| 342 | const QChar ch = cacheFile->getUint32(off); | - |
| 343 | if (ch < fileChar)| TRUE | evaluated 7882 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 10446 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 7882-10446 |
| 344 | min = mid + 1;executed 7882 times by 22 tests: min = mid + 1;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 7882 |
| 345 | else if (ch > fileChar)| TRUE | evaluated 354 times by 3 testsEvaluated by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| | FALSE | evaluated 10092 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 354-10092 |
| 346 | max = mid - 1;executed 354 times by 3 tests: max = mid - 1;Executed by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| 354 |
| 347 | else { | - |
| 348 | --charPos; | - |
| 349 | int numChildren = cacheFile->getUint32(off + 4); | - |
| 350 | int childrenOffset = cacheFile->getUint32(off + 8); | - |
| 351 | bool success = false; | - |
| 352 | if (charPos > 0)| TRUE | evaluated 10086 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 6 times by 1 test |
| 6-10086 |
| 353 | success = matchSuffixTree(result, cacheFile, numChildren, childrenOffset, fileName, charPos, caseSensitiveCheck);executed 10086 times by 22 tests: success = matchSuffixTree(result, cacheFile, numChildren, childrenOffset, fileName, charPos, caseSensitiveCheck);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 10086 |
| 354 | if (!success) {| TRUE | evaluated 2608 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 7484 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2608-7484 |
| 355 | for (int i = 0; i < numChildren; ++i) {| TRUE | evaluated 5043 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2484 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2484-5043 |
| 356 | const int childOff = childrenOffset + 12 * i; | - |
| 357 | const int mch = cacheFile->getUint32(childOff); | - |
| 358 | if (mch != 0)| TRUE | evaluated 124 times by 3 testsEvaluated by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| | FALSE | evaluated 4919 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 124-4919 |
| 359 | break;executed 124 times by 3 tests: break;Executed by:- tst_QGraphicsWidget
- tst_QIcon
- tst_QMimeDatabase
| 124 |
| 360 | const int mimeTypeOffset = cacheFile->getUint32(childOff + 4); | - |
| 361 | const char *mimeType = cacheFile->getCharStar(mimeTypeOffset); | - |
| 362 | const int flagsAndWeight = cacheFile->getUint32(childOff + 8); | - |
| 363 | const int weight = flagsAndWeight & 0xff; | - |
| 364 | const bool caseSensitive = flagsAndWeight & 0x100; | - |
| 365 | if (caseSensitiveCheck || !caseSensitive) {| TRUE | evaluated 4 times by 1 test | | FALSE | evaluated 4915 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| TRUE | evaluated 4911 times by 21 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 4 times by 1 test |
| 4-4915 |
| 366 | result.addMatch(QLatin1String(mimeType), weight, QLatin1Char('*') + fileName.mid(charPos+1)); | - |
| 367 | success = true; | - |
| 368 | }executed 4915 times by 21 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 4915 |
| 369 | }executed 4919 times by 21 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 4919 |
| 370 | }executed 2608 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2608 |
| 371 | return success;executed 10092 times by 22 tests: return success;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 10092 |
| 372 | } | - |
| 373 | } | - |
| 374 | return false;executed 2554 times by 22 tests: return false;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2554 |
| 375 | } | - |
| 376 | | - |
| 377 | bool QMimeBinaryProvider::matchMagicRule(QMimeBinaryProvider::CacheFile *cacheFile, int numMatchlets, int firstOffset, const QByteArray &data) | - |
| 378 | { | - |
| 379 | const char *dataPtr = data.constData(); | - |
| 380 | const int dataSize = data.size(); | - |
| 381 | for (int matchlet = 0; matchlet < numMatchlets; ++matchlet) {| TRUE | evaluated 10116 times by 1 test | | FALSE | evaluated 5890 times by 1 test |
| 5890-10116 |
| 382 | const int off = firstOffset + matchlet * 32; | - |
| 383 | const int rangeStart = cacheFile->getUint32(off); | - |
| 384 | const int rangeLength = cacheFile->getUint32(off + 4); | - |
| 385 | | - |
| 386 | const int valueLength = cacheFile->getUint32(off + 12); | - |
| 387 | const int valueOffset = cacheFile->getUint32(off + 16); | - |
| 388 | const int maskOffset = cacheFile->getUint32(off + 20); | - |
| 389 | const char *mask = maskOffset ? cacheFile->getCharStar(maskOffset) : NULL;| TRUE | evaluated 215 times by 1 test | | FALSE | evaluated 9901 times by 1 test |
| 215-9901 |
| 390 | | - |
| 391 | if (!QMimeMagicRule::matchSubstring(dataPtr, dataSize, rangeStart, rangeLength, valueLength, cacheFile->getCharStar(valueOffset), mask))| TRUE | evaluated 10071 times by 1 test | | FALSE | evaluated 45 times by 1 test |
| 45-10071 |
| 392 | continue;executed 10071 times by 1 test: continue; | 10071 |
| 393 | | - |
| 394 | const int numChildren = cacheFile->getUint32(off + 24); | - |
| 395 | const int firstChildOffset = cacheFile->getUint32(off + 28); | - |
| 396 | if (numChildren == 0) | TRUE | evaluated 23 times by 1 test | | FALSE | evaluated 22 times by 1 test |
| 22-23 |
| 397 | return true;executed 23 times by 1 test: return true; | 23 |
| 398 | | - |
| 399 | if (matchMagicRule(cacheFile, numChildren, firstChildOffset, data))| TRUE | evaluated 4 times by 1 test | | FALSE | evaluated 18 times by 1 test |
| 4-18 |
| 400 | return true;executed 4 times by 1 test: return true; | 4 |
| 401 | }executed 18 times by 1 test: end of block | 18 |
| 402 | return false;executed 5890 times by 1 test: return false; | 5890 |
| 403 | } | - |
| 404 | | - |
| 405 | QMimeType QMimeBinaryProvider::findByMagic(const QByteArray &data, int *accuracyPtr) | - |
| 406 | { | - |
| 407 | checkCache(); | - |
| 408 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 409 | const int magicListOffset = cacheFile->getUint32(PosMagicListOffset); | - |
| 410 | const int numMatches = cacheFile->getUint32(magicListOffset); | - |
| 411 | | - |
| 412 | const int firstMatchOffset = cacheFile->getUint32(magicListOffset + 8); | - |
| 413 | | - |
| 414 | for (int i = 0; i < numMatches; ++i) {| TRUE | evaluated 5895 times by 1 test | | FALSE | evaluated 9 times by 1 test |
| 9-5895 |
| 415 | const int off = firstMatchOffset + i * 16; | - |
| 416 | const int numMatchlets = cacheFile->getUint32(off + 8); | - |
| 417 | const int firstMatchletOffset = cacheFile->getUint32(off + 12); | - |
| 418 | if (matchMagicRule(cacheFile, numMatchlets, firstMatchletOffset, data)) {| TRUE | evaluated 23 times by 1 test | | FALSE | evaluated 5872 times by 1 test |
| 23-5872 |
| 419 | const int mimeTypeOffset = cacheFile->getUint32(off + 4); | - |
| 420 | const char *mimeType = cacheFile->getCharStar(mimeTypeOffset); | - |
| 421 | *accuracyPtr = cacheFile->getUint32(off); | - |
| 422 | | - |
| 423 | | - |
| 424 | return mimeTypeForNameUnchecked(QLatin1String(mimeType));executed 23 times by 1 test: return mimeTypeForNameUnchecked(QLatin1String(mimeType)); | 23 |
| 425 | } | - |
| 426 | }executed 5872 times by 1 test: end of block | 5872 |
| 427 | }executed 9 times by 1 test: end of block | 9 |
| 428 | return QMimeType();executed 9 times by 1 test: return QMimeType(); | 9 |
| 429 | } | - |
| 430 | | - |
| 431 | QStringList QMimeBinaryProvider::parents(const QString &mime) | - |
| 432 | { | - |
| 433 | checkCache(); | - |
| 434 | const QByteArray mimeStr = mime.toLatin1(); | - |
| 435 | QStringList result; | - |
| 436 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 437 | const int parentListOffset = cacheFile->getUint32(PosParentListOffset); | - |
| 438 | const int numEntries = cacheFile->getUint32(parentListOffset); | - |
| 439 | | - |
| 440 | int begin = 0; | - |
| 441 | int end = numEntries - 1; | - |
| 442 | while (begin <= end) {| TRUE | evaluated 466 times by 1 test | | FALSE | evaluated 34 times by 1 test |
| 34-466 |
| 443 | const int medium = (begin + end) / 2; | - |
| 444 | const int off = parentListOffset + 4 + 8 * medium; | - |
| 445 | const int mimeOffset = cacheFile->getUint32(off); | - |
| 446 | const char *aMime = cacheFile->getCharStar(mimeOffset); | - |
| 447 | const int cmp = qstrcmp(aMime, mimeStr); | - |
| 448 | if (cmp < 0) {| TRUE | evaluated 230 times by 1 test | | FALSE | evaluated 236 times by 1 test |
| 230-236 |
| 449 | begin = medium + 1; | - |
| 450 | } else if (cmp > 0) {executed 230 times by 1 test: end of block | TRUE | evaluated 210 times by 1 test | | FALSE | evaluated 26 times by 1 test |
| 26-230 |
| 451 | end = medium - 1; | - |
| 452 | } else {executed 210 times by 1 test: end of block | 210 |
| 453 | const int parentsOffset = cacheFile->getUint32(off + 4); | - |
| 454 | const int numParents = cacheFile->getUint32(parentsOffset); | - |
| 455 | for (int i = 0; i < numParents; ++i) {| TRUE | evaluated 34 times by 1 test | | FALSE | evaluated 26 times by 1 test |
| 26-34 |
| 456 | const int parentOffset = cacheFile->getUint32(parentsOffset + 4 + 4 * i); | - |
| 457 | const char *aParent = cacheFile->getCharStar(parentOffset); | - |
| 458 | result.append(QString::fromLatin1(aParent)); | - |
| 459 | }executed 34 times by 1 test: end of block | 34 |
| 460 | break;executed 26 times by 1 test: break; | 26 |
| 461 | } | - |
| 462 | } | - |
| 463 | }executed 60 times by 1 test: end of block | 60 |
| 464 | if (result.isEmpty()) {| TRUE | evaluated 34 times by 1 test | | FALSE | evaluated 26 times by 1 test |
| 26-34 |
| 465 | const QString parent = fallbackParent(mime); | - |
| 466 | if (!parent.isEmpty())| TRUE | evaluated 22 times by 1 test | | FALSE | evaluated 12 times by 1 test |
| 12-22 |
| 467 | result.append(parent);executed 22 times by 1 test: result.append(parent); | 22 |
| 468 | }executed 34 times by 1 test: end of block | 34 |
| 469 | return result;executed 60 times by 1 test: return result; | 60 |
| 470 | } | - |
| 471 | | - |
| 472 | QString QMimeBinaryProvider::resolveAlias(const QString &name) | - |
| 473 | { | - |
| 474 | checkCache(); | - |
| 475 | const QByteArray input = name.toLatin1(); | - |
| 476 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 477 | const int aliasListOffset = cacheFile->getUint32(PosAliasListOffset); | - |
| 478 | const int numEntries = cacheFile->getUint32(aliasListOffset); | - |
| 479 | int begin = 0; | - |
| 480 | int end = numEntries - 1; | - |
| 481 | while (begin <= end) {| TRUE | evaluated 36002 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 4609 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 4609-36002 |
| 482 | const int medium = (begin + end) / 2; | - |
| 483 | const int off = aliasListOffset + 4 + 8 * medium; | - |
| 484 | const int aliasOffset = cacheFile->getUint32(off); | - |
| 485 | const char *alias = cacheFile->getCharStar(aliasOffset); | - |
| 486 | const int cmp = qstrcmp(alias, input); | - |
| 487 | if (cmp < 0) {| TRUE | evaluated 18281 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 17721 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 17721-18281 |
| 488 | begin = medium + 1; | - |
| 489 | } else if (cmp > 0) {executed 18281 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| TRUE | evaluated 17712 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 9 times by 1 test |
| 9-18281 |
| 490 | end = medium - 1; | - |
| 491 | } else {executed 17712 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 17712 |
| 492 | const int mimeOffset = cacheFile->getUint32(off + 4); | - |
| 493 | const char *mimeType = cacheFile->getCharStar(mimeOffset); | - |
| 494 | return QLatin1String(mimeType);executed 9 times by 1 test: return QLatin1String(mimeType); | 9 |
| 495 | } | - |
| 496 | } | - |
| 497 | }executed 4609 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 4609 |
| 498 | | - |
| 499 | return name;executed 4598 times by 23 tests: return name;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 4598 |
| 500 | } | - |
| 501 | | - |
| 502 | QStringList QMimeBinaryProvider::listAliases(const QString &name) | - |
| 503 | { | - |
| 504 | checkCache(); | - |
| 505 | QStringList result; | - |
| 506 | const QByteArray input = name.toLatin1(); | - |
| 507 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 508 | const int aliasListOffset = cacheFile->getUint32(PosAliasListOffset); | - |
| 509 | const int numEntries = cacheFile->getUint32(aliasListOffset); | - |
| 510 | for (int pos = 0; pos < numEntries; ++pos) {| TRUE | evaluated 776 times by 1 test | | FALSE | evaluated 4 times by 1 test |
| 4-776 |
| 511 | const int off = aliasListOffset + 4 + 8 * pos; | - |
| 512 | const int mimeOffset = cacheFile->getUint32(off + 4); | - |
| 513 | const char *mimeType = cacheFile->getCharStar(mimeOffset); | - |
| 514 | | - |
| 515 | if (input == mimeType) {| TRUE | evaluated 4 times by 1 test | | FALSE | evaluated 772 times by 1 test |
| 4-772 |
| 516 | const int aliasOffset = cacheFile->getUint32(off); | - |
| 517 | const char *alias = cacheFile->getCharStar(aliasOffset); | - |
| 518 | result.append(QString::fromLatin1(alias)); | - |
| 519 | }executed 4 times by 1 test: end of block | 4 |
| 520 | }executed 776 times by 1 test: end of block | 776 |
| 521 | }executed 4 times by 1 test: end of block | 4 |
| 522 | return result;executed 4 times by 1 test: return result; | 4 |
| 523 | } | - |
| 524 | | - |
| 525 | void QMimeBinaryProvider::loadMimeTypeList() | - |
| 526 | { | - |
| 527 | if (!m_mimetypeListLoaded) {| TRUE | evaluated 28 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 5 times by 1 test |
| 5-28 |
| 528 | m_mimetypeListLoaded = true; | - |
| 529 | m_mimetypeNames.clear(); | - |
| 530 | | - |
| 531 | | - |
| 532 | const QStringList typesFilenames = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QLatin1String("mime/types")); | - |
| 533 | for (const QString &typeFilename : typesFilenames) { | - |
| 534 | QFile file(typeFilename); | - |
| 535 | if (file.open(QIODevice::ReadOnly)) {| TRUE | evaluated 31 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-31 |
| 536 | while (!file.atEnd()) {| TRUE | evaluated 19818 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 31 times by 23 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 31-19818 |
| 537 | QByteArray line = file.readLine(); | - |
| 538 | line.chop(1); | - |
| 539 | m_mimetypeNames.insert(QString::fromLatin1(line.constData(), line.size())); | - |
| 540 | }executed 19818 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 19818 |
| 541 | }executed 31 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 31 |
| 542 | }executed 31 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 31 |
| 543 | }executed 28 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 28 |
| 544 | }executed 33 times by 23 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QDebug
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 33 |
| 545 | | - |
| 546 | QList<QMimeType> QMimeBinaryProvider::allMimeTypes() | - |
| 547 | { | - |
| 548 | QList<QMimeType> result; | - |
| 549 | loadMimeTypeList(); | - |
| 550 | result.reserve(m_mimetypeNames.count()); | - |
| 551 | | - |
| 552 | for (QSet<QString>::const_iterator it = m_mimetypeNames.constBegin(); | - |
| 553 | it != m_mimetypeNames.constEnd(); ++it)| TRUE | evaluated 3315 times by 1 test | | FALSE | evaluated 5 times by 1 test |
| 5-3315 |
| 554 | result.append(mimeTypeForNameUnchecked(*it));executed 3315 times by 1 test: result.append(mimeTypeForNameUnchecked(*it)); | 3315 |
| 555 | | - |
| 556 | return result;executed 5 times by 1 test: return result; | 5 |
| 557 | } | - |
| 558 | | - |
| 559 | void QMimeBinaryProvider::loadMimeTypePrivate(QMimeTypePrivate &data) | - |
| 560 | { | - |
| 561 | #ifdef QT_NO_XMLSTREAMREADER | - |
| 562 | qWarning("Cannot load mime type since QXmlStreamReader is not available."); | - |
| 563 | return; | - |
| 564 | #else | - |
| 565 | if (data.loaded)| TRUE | evaluated 10 times by 1 test | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 10-2447 |
| 566 | return;executed 10 times by 1 test: return; | 10 |
| 567 | data.loaded = true; | - |
| 568 | | - |
| 569 | | - |
| 570 | const QString file = data.name + QLatin1String(".xml"); | - |
| 571 | | - |
| 572 | QStringList mimeFiles = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QString::fromLatin1("mime/") + file.toLower()); | - |
| 573 | if (mimeFiles.isEmpty()) {| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 574 | mimeFiles = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QString::fromLatin1("mime/") + file); | - |
| 575 | } never executed: end of block | 0 |
| 576 | if (mimeFiles.isEmpty()) {| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 577 | qWarning() << "No file found for" << file << ", even though update-mime-info said it would exist.\n" | - |
| 578 | "Either it was just removed, or the directory doesn't have executable permission..." | - |
| 579 | << QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QLatin1String("mime"), QStandardPaths::LocateDirectory); | - |
| 580 | return; never executed: return; | 0 |
| 581 | } | - |
| 582 | | - |
| 583 | QString mainPattern; | - |
| 584 | | - |
| 585 | for (QStringList::const_reverse_iterator it = mimeFiles.crbegin(), end = mimeFiles.crend(); it != end; ++it) { | TRUE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2447 |
| 586 | QFile qfile(*it); | - |
| 587 | if (!qfile.open(QFile::ReadOnly))| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 588 | continue; never executed: continue; | 0 |
| 589 | | - |
| 590 | QXmlStreamReader xml(&qfile); | - |
| 591 | if (xml.readNextStartElement()) {| TRUE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-2447 |
| 592 | if (xml.name() != QLatin1String("mime-type")) {| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 593 | continue; never executed: continue; | 0 |
| 594 | } | - |
| 595 | const QStringRef name = xml.attributes().value(QLatin1String("type")); | - |
| 596 | if (name.isEmpty())| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 597 | continue; never executed: continue; | 0 |
| 598 | if (name.compare(data.name, Qt::CaseInsensitive))| TRUE | never evaluated | | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2447 |
| 599 | qWarning() << "Got name" << name << "in file" << file << "expected" << data.name; never executed: QMessageLogger(__FILE__, 599, __PRETTY_FUNCTION__).warning() << "Got name" << name << "in file" << file << "expected" << data.name; | 0 |
| 600 | | - |
| 601 | while (xml.readNextStartElement()) {| TRUE | evaluated 117409 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2447-117409 |
| 602 | const QStringRef tag = xml.name(); | - |
| 603 | if (tag == QLatin1String("comment")) {| TRUE | evaluated 114909 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 2500 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2500-114909 |
| 604 | QString lang = xml.attributes().value(QLatin1String("xml:lang")).toString(); | - |
| 605 | const QString text = xml.readElementText(); | - |
| 606 | if (lang.isEmpty()) {| TRUE | evaluated 2447 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 112462 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 2447-112462 |
| 607 | lang = QLatin1String("en_US"); | - |
| 608 | }executed 2447 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2447 |
| 609 | data.localeComments.insert(lang, text); | - |
| 610 | continue; executed 114909 times by 22 tests: continue;Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 114909 |
| 611 | } else if (tag == QLatin1String("icon")) { | TRUE | never evaluated | | FALSE | evaluated 2500 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2500 |
| 612 | data.iconName = xml.attributes().value(QLatin1String("name")).toString(); | - |
| 613 | } else if (tag == QLatin1String("glob-deleteall")) { never executed: end of block | TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 2499 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2499 |
| 614 | data.globPatterns.clear(); | - |
| 615 | } else if (tag == QLatin1String("glob")) { executed 1 time by 1 test: end of block | TRUE | evaluated 2463 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 36 times by 2 testsEvaluated by:- tst_QIcon
- tst_QMimeDatabase
|
| 1-2463 |
| 616 | const QString pattern = xml.attributes().value(QLatin1String("pattern")).toString(); | - |
| 617 | if (mainPattern.isEmpty() && pattern.startsWith(QLatin1Char('*'))) {| TRUE | evaluated 2443 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 20 times by 2 testsEvaluated by:- tst_QIcon
- tst_QMimeDatabase
|
| TRUE | evaluated 2442 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 1 time by 1 test |
| 1-2443 |
| 618 | mainPattern = pattern; | - |
| 619 | }executed 2442 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2442 |
| 620 | if (!data.globPatterns.contains(pattern))| TRUE | evaluated 2463 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | never evaluated |
| 0-2463 |
| 621 | data.globPatterns.append(pattern);executed 2463 times by 22 tests: data.globPatterns.append(pattern);Executed by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2463 |
| 622 | }executed 2463 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2463 |
| 623 | xml.skipCurrentElement(); | - |
| 624 | }executed 2500 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2500 |
| 625 | Q_ASSERT(xml.name() == QLatin1String("mime-type")); | - |
| 626 | }executed 2447 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2447 |
| 627 | }executed 2447 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2447 |
| 628 | | - |
| 629 | | - |
| 630 | | - |
| 631 | #if 1 | - |
| 632 | if (!mainPattern.isEmpty() && (data.globPatterns.isEmpty() || data.globPatterns.constFirst() != mainPattern)) {| TRUE | evaluated 2442 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| | FALSE | evaluated 5 times by 1 test |
| TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 2441 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| TRUE | never evaluated | | FALSE | evaluated 2441 times by 22 testsEvaluated by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
|
| 0-2442 |
| 633 | | - |
| 634 | data.globPatterns.removeAll(mainPattern); | - |
| 635 | data.globPatterns.prepend(mainPattern); | - |
| 636 | }executed 1 time by 1 test: end of block | 1 |
| 637 | #else | - |
| 638 | const bool globsInXml = sharedMimeInfoVersion() >= QT_VERSION_CHECK(0, 70, 0); | - |
| 639 | if (globsInXml) { | - |
| 640 | if (!mainPattern.isEmpty() && data.globPatterns.constFirst() != mainPattern) { | - |
| 641 | | - |
| 642 | data.globPatterns.removeAll(mainPattern); | - |
| 643 | data.globPatterns.prepend(mainPattern); | - |
| 644 | } | - |
| 645 | } else { | - |
| 646 | | - |
| 647 | | - |
| 648 | | - |
| 649 | } | - |
| 650 | #endif | - |
| 651 | #endif //QT_NO_XMLSTREAMREADER | - |
| 652 | }executed 2447 times by 22 tests: end of blockExecuted by:- tst_QAccessibility
- tst_QCalendarWidget
- tst_QComboBox
- tst_QCompleter
- tst_QDateTimeEdit
- tst_QFileDialog2
- tst_QFileIconProvider
- tst_QFileSystemModel
- tst_QFiledialog
- tst_QFontComboBox
- tst_QGraphicsProxyWidget
- tst_QGraphicsWidget
- tst_QGuiApplication
- tst_QGuiVariant
- tst_QIcon
- tst_QMimeDatabase
- tst_QPrinter
- tst_QSidebar
- tst_QStyle
- tst_QSystemTrayIcon
- tst_QToolButton
- tst_languageChange
| 2447 |
| 653 | | - |
| 654 | | - |
| 655 | QString QMimeBinaryProvider::iconForMime(CacheFile *cacheFile, int posListOffset, const QByteArray &inputMime) | - |
| 656 | { | - |
| 657 | const int iconsListOffset = cacheFile->getUint32(posListOffset); | - |
| 658 | const int numIcons = cacheFile->getUint32(iconsListOffset); | - |
| 659 | int begin = 0; | - |
| 660 | int end = numIcons - 1; | - |
| 661 | while (begin <= end) {| TRUE | evaluated 34 times by 1 test | | FALSE | evaluated 6 times by 1 test |
| 6-34 |
| 662 | const int medium = (begin + end) / 2; | - |
| 663 | const int off = iconsListOffset + 4 + 8 * medium; | - |
| 664 | const int mimeOffset = cacheFile->getUint32(off); | - |
| 665 | const char *mime = cacheFile->getCharStar(mimeOffset); | - |
| 666 | const int cmp = qstrcmp(mime, inputMime); | - |
| 667 | if (cmp < 0)| TRUE | evaluated 18 times by 1 test | | FALSE | evaluated 16 times by 1 test |
| 16-18 |
| 668 | begin = medium + 1;executed 18 times by 1 test: begin = medium + 1; | 18 |
| 669 | else if (cmp > 0)| TRUE | evaluated 14 times by 1 test | | FALSE | evaluated 2 times by 1 test |
| 2-14 |
| 670 | end = medium - 1;executed 14 times by 1 test: end = medium - 1; | 14 |
| 671 | else { | - |
| 672 | const int iconOffset = cacheFile->getUint32(off + 4); | - |
| 673 | return QLatin1String(cacheFile->getCharStar(iconOffset));executed 2 times by 1 test: return QLatin1String(cacheFile->getCharStar(iconOffset)); | 2 |
| 674 | } | - |
| 675 | } | - |
| 676 | return QString();executed 6 times by 1 test: return QString(); | 6 |
| 677 | } | - |
| 678 | | - |
| 679 | void QMimeBinaryProvider::loadIcon(QMimeTypePrivate &data) | - |
| 680 | { | - |
| 681 | checkCache(); | - |
| 682 | const QByteArray inputMime = data.name.toLatin1(); | - |
| 683 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 684 | const QString icon = iconForMime(cacheFile, PosIconsListOffset, inputMime); | - |
| 685 | if (!icon.isEmpty()) {| TRUE | never evaluated | | FALSE | evaluated 4 times by 1 test |
| 0-4 |
| 686 | data.iconName = icon; | - |
| 687 | return; never executed: return; | 0 |
| 688 | } | - |
| 689 | }executed 4 times by 1 test: end of block | 4 |
| 690 | }executed 4 times by 1 test: end of block | 4 |
| 691 | | - |
| 692 | void QMimeBinaryProvider::loadGenericIcon(QMimeTypePrivate &data) | - |
| 693 | { | - |
| 694 | checkCache(); | - |
| 695 | const QByteArray inputMime = data.name.toLatin1(); | - |
| 696 | for (CacheFile *cacheFile : qAsConst(m_cacheFiles)) { | - |
| 697 | const QString icon = iconForMime(cacheFile, PosGenericIconsListOffset, inputMime); | - |
| 698 | if (!icon.isEmpty()) {| TRUE | evaluated 2 times by 1 test | | FALSE | evaluated 2 times by 1 test |
| 2 |
| 699 | data.genericIconName = icon; | - |
| 700 | return;executed 2 times by 1 test: return; | 2 |
| 701 | } | - |
| 702 | }executed 2 times by 1 test: end of block | 2 |
| 703 | }executed 2 times by 1 test: end of block | 2 |
| 704 | | - |
| 705 | | - |
| 706 | | - |
| 707 | QMimeXMLProvider::QMimeXMLProvider(QMimeDatabasePrivate *db) | - |
| 708 | : QMimeProviderBase(db), m_loaded(false) | - |
| 709 | { | - |
| 710 | initResources(); | - |
| 711 | }executed 2 times by 2 tests: end of blockExecuted by:- tst_QMimeDatabase
- tst_qmimetype
| 2 |
| 712 | | - |
| 713 | QMimeXMLProvider::~QMimeXMLProvider() | - |
| 714 | { | - |
| 715 | } | - |
| 716 | | - |
| 717 | bool QMimeXMLProvider::isValid() | - |
| 718 | { | - |
| 719 | return true; never executed: return true; | 0 |
| 720 | } | - |
| 721 | | - |
| 722 | QMimeType QMimeXMLProvider::mimeTypeForName(const QString &name) | - |
| 723 | { | - |
| 724 | ensureLoaded(); | - |
| 725 | | - |
| 726 | return m_nameMimeTypeMap.value(name);executed 2183 times by 1 test: return m_nameMimeTypeMap.value(name); | 2183 |
| 727 | } | - |
| 728 | | - |
| 729 | QStringList QMimeXMLProvider::findByFileName(const QString &fileName, QString *foundSuffix) | - |
| 730 | { | - |
| 731 | ensureLoaded(); | - |
| 732 | | - |
| 733 | const QStringList matchingMimeTypes = m_mimeTypeGlobs.matchingGlobs(fileName, foundSuffix); | - |
| 734 | return matchingMimeTypes;executed 96 times by 1 test: return matchingMimeTypes; | 96 |
| 735 | } | - |
| 736 | | - |
| 737 | QMimeType QMimeXMLProvider::findByMagic(const QByteArray &data, int *accuracyPtr) | - |
| 738 | { | - |
| 739 | ensureLoaded(); | - |
| 740 | | - |
| 741 | QString candidate; | - |
| 742 | | - |
| 743 | for (const QMimeMagicRuleMatcher &matcher : qAsConst(m_magicMatchers)) { | - |
| 744 | if (matcher.matches(data)) {| TRUE | evaluated 37 times by 1 test | | FALSE | evaluated 11003 times by 1 test |
| 37-11003 |
| 745 | const int priority = matcher.priority(); | - |
| 746 | if (priority > *accuracyPtr) {| TRUE | evaluated 23 times by 1 test | | FALSE | evaluated 14 times by 1 test |
| 14-23 |
| 747 | *accuracyPtr = priority; | - |
| 748 | candidate = matcher.mimetype(); | - |
| 749 | }executed 23 times by 1 test: end of block | 23 |
| 750 | }executed 37 times by 1 test: end of block | 37 |
| 751 | }executed 11040 times by 1 test: end of block | 11040 |
| 752 | return mimeTypeForName(candidate);executed 32 times by 1 test: return mimeTypeForName(candidate); | 32 |
| 753 | } | - |
| 754 | | - |
| 755 | void QMimeXMLProvider::ensureLoaded() | - |
| 756 | { | - |
| 757 | if (!m_loaded || shouldCheck()) {| TRUE | evaluated 1 time by 1 test | | FALSE | evaluated 4556 times by 1 test |
| TRUE | evaluated 56 times by 1 test | | FALSE | evaluated 4500 times by 1 test |
| 1-4556 |
| 758 | bool fdoXmlFound = false; | - |
| 759 | QStringList allFiles; | - |
| 760 | | - |
| 761 | const QStringList packageDirs = QStandardPaths::locateAll(QStandardPaths::GenericDataLocation, QLatin1String("mime/packages"), QStandardPaths::LocateDirectory); | - |
| 762 | | - |
| 763 | for (const QString &packageDir : packageDirs) { | - |
| 764 | QDir dir(packageDir); | - |
| 765 | const QStringList files = dir.entryList(QDir::Files | QDir::NoDotAndDotDot); | - |
| 766 | | - |
| 767 | if (!fdoXmlFound)| TRUE | evaluated 88 times by 1 test | | FALSE | never evaluated |
| 0-88 |
| 768 | fdoXmlFound = files.contains(QLatin1String("freedesktop.org.xml"));executed 88 times by 1 test: fdoXmlFound = files.contains(QLatin1String("freedesktop.org.xml")); | 88 |
| 769 | QStringList::const_iterator endIt(files.constEnd()); | - |
| 770 | for (QStringList::const_iterator it(files.constBegin()); it != endIt; ++it) {| TRUE | evaluated 261 times by 1 test | | FALSE | evaluated 88 times by 1 test |
| 88-261 |
| 771 | allFiles.append(packageDir + QLatin1Char('/') + *it); | - |
| 772 | }executed 261 times by 1 test: end of block | 261 |
| 773 | }executed 88 times by 1 test: end of block | 88 |
| 774 | | - |
| 775 | if (!fdoXmlFound) {| TRUE | never evaluated | | FALSE | evaluated 57 times by 1 test |
| 0-57 |
| 776 | | - |
| 777 | allFiles.prepend(QLatin1String(":/qt-project.org/qmime/freedesktop.org.xml")); | - |
| 778 | } never executed: end of block | 0 |
| 779 | | - |
| 780 | if (m_allFiles == allFiles)| TRUE | evaluated 52 times by 1 test | | FALSE | evaluated 5 times by 1 test |
| 5-52 |
| 781 | return;executed 52 times by 1 test: return; | 52 |
| 782 | m_allFiles = allFiles; | - |
| 783 | | - |
| 784 | m_nameMimeTypeMap.clear(); | - |
| 785 | m_aliases.clear(); | - |
| 786 | m_parents.clear(); | - |
| 787 | m_mimeTypeGlobs.clear(); | - |
| 788 | m_magicMatchers.clear(); | - |
| 789 | | - |
| 790 | | - |
| 791 | | - |
| 792 | for (const QString &file : qAsConst(allFiles)) | - |
| 793 | load(file);executed 17 times by 1 test: load(file); | 17 |
| 794 | }executed 5 times by 1 test: end of block | 5 |
| 795 | }executed 4505 times by 1 test: end of block | 4505 |
| 796 | | - |
| 797 | void QMimeXMLProvider::load(const QString &fileName) | - |
| 798 | { | - |
| 799 | QString errorMessage; | - |
| 800 | if (!load(fileName, &errorMessage))| TRUE | never evaluated | | FALSE | evaluated 17 times by 1 test |
| 0-17 |
| 801 | qWarning("QMimeDatabase: Error loading %s\n%s", qPrintable(fileName), qPrintable(errorMessage)); never executed: QMessageLogger(__FILE__, 801, __PRETTY_FUNCTION__).warning("QMimeDatabase: Error loading %s\n%s", QString(fileName).toLocal8Bit().constData(), QString(errorMessage).toLocal8Bit().constData()); | 0 |
| 802 | }executed 17 times by 1 test: end of block | 17 |
| 803 | | - |
| 804 | bool QMimeXMLProvider::load(const QString &fileName, QString *errorMessage) | - |
| 805 | { | - |
| 806 | m_loaded = true; | - |
| 807 | | - |
| 808 | QFile file(fileName); | - |
| 809 | if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {| TRUE | never evaluated | | FALSE | evaluated 17 times by 1 test |
| 0-17 |
| 810 | if (errorMessage)| TRUE | never evaluated | | FALSE | never evaluated |
| 0 |
| 811 | *errorMessage = QString::fromLatin1("Cannot open %1: %2").arg(fileName, file.errorString()); never executed: *errorMessage = QString::fromLatin1("Cannot open %1: %2").arg(fileName, file.errorString()); | 0 |
| 812 | return false; never executed: return false; | 0 |
| 813 | } | - |
| 814 | | - |
| 815 | if (errorMessage)| TRUE | evaluated 17 times by 1 test | | FALSE | never evaluated |
| 0-17 |
| 816 | errorMessage->clear();executed 17 times by 1 test: errorMessage->clear(); | 17 |
| 817 | | - |
| 818 | QMimeTypeParser parser(*this); | - |
| 819 | return parser.parse(&file, fileName, errorMessage);executed 17 times by 1 test: return parser.parse(&file, fileName, errorMessage); | 17 |
| 820 | } | - |
| 821 | | - |
| 822 | void QMimeXMLProvider::addGlobPattern(const QMimeGlobPattern &glob) | - |
| 823 | { | - |
| 824 | m_mimeTypeGlobs.addGlob(glob); | - |
| 825 | }executed 4136 times by 1 test: end of block | 4136 |
| 826 | | - |
| 827 | void QMimeXMLProvider::addMimeType(const QMimeType &mt) | - |
| 828 | { | - |
| 829 | m_nameMimeTypeMap.insert(mt.name(), mt); | - |
| 830 | }executed 3319 times by 1 test: end of block | 3319 |
| 831 | | - |
| 832 | QStringList QMimeXMLProvider::parents(const QString &mime) | - |
| 833 | { | - |
| 834 | ensureLoaded(); | - |
| 835 | QStringList result = m_parents.value(mime); | - |
| 836 | if (result.isEmpty()) {| TRUE | evaluated 34 times by 1 test | | FALSE | evaluated 26 times by 1 test |
| 26-34 |
| 837 | const QString parent = fallbackParent(mime); | - |
| 838 | if (!parent.isEmpty())| TRUE | evaluated 22 times by 1 test | | FALSE | evaluated 12 times by 1 test |
| 12-22 |
| 839 | result.append(parent);executed 22 times by 1 test: result.append(parent); | 22 |
| 840 | }executed 34 times by 1 test: end of block | 34 |
| 841 | return result;executed 60 times by 1 test: return result; | 60 |
| 842 | } | - |
| 843 | | - |
| 844 | void QMimeXMLProvider::addParent(const QString &child, const QString &parent) | - |
| 845 | { | - |
| 846 | m_parents[child].append(parent); | - |
| 847 | }executed 1560 times by 1 test: end of block | 1560 |
| 848 | | - |
| 849 | QStringList QMimeXMLProvider::listAliases(const QString &name) | - |
| 850 | { | - |
| 851 | ensureLoaded(); | - |
| 852 | | - |
| 853 | return m_aliases.keys(name);executed 4 times by 1 test: return m_aliases.keys(name); | 4 |
| 854 | } | - |
| 855 | | - |
| 856 | QString QMimeXMLProvider::resolveAlias(const QString &name) | - |
| 857 | { | - |
| 858 | ensureLoaded(); | - |
| 859 | return m_aliases.value(name, name);executed 2177 times by 1 test: return m_aliases.value(name, name); | 2177 |
| 860 | } | - |
| 861 | | - |
| 862 | void QMimeXMLProvider::addAlias(const QString &alias, const QString &name) | - |
| 863 | { | - |
| 864 | m_aliases.insert(alias, name); | - |
| 865 | }executed 975 times by 1 test: end of block | 975 |
| 866 | | - |
| 867 | QList<QMimeType> QMimeXMLProvider::allMimeTypes() | - |
| 868 | { | - |
| 869 | ensureLoaded(); | - |
| 870 | return m_nameMimeTypeMap.values();executed 5 times by 1 test: return m_nameMimeTypeMap.values(); | 5 |
| 871 | } | - |
| 872 | | - |
| 873 | void QMimeXMLProvider::addMagicMatcher(const QMimeMagicRuleMatcher &matcher) | - |
| 874 | { | - |
| 875 | m_magicMatchers.append(matcher); | - |
| 876 | }executed 1733 times by 1 test: end of block | 1733 |
| 877 | | - |
| 878 | QT_END_NAMESPACE | - |
| 879 | | - |
| 880 | #endif // QT_NO_MIMETYPE | - |
| | |