summaryrefslogtreecommitdiffstats
path: root/tests/auto/tools/rcc/tst_rcc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/tools/rcc/tst_rcc.cpp')
-rw-r--r--tests/auto/tools/rcc/tst_rcc.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/auto/tools/rcc/tst_rcc.cpp b/tests/auto/tools/rcc/tst_rcc.cpp
index dbf5cebd9d..8af85a6d09 100644
--- a/tests/auto/tools/rcc/tst_rcc.cpp
+++ b/tests/auto/tools/rcc/tst_rcc.cpp
@@ -52,6 +52,7 @@
#include <QtCore/QList>
#include <QtCore/QResource>
#include <QtCore/QLocale>
+#include <QtCore/QtGlobal>
typedef QMap<QString, QString> QStringMap;
Q_DECLARE_METATYPE(QStringMap)
@@ -61,6 +62,8 @@ class tst_rcc : public QObject
Q_OBJECT
private slots:
+ void initTestCase();
+
void rcc_data();
void rcc();
void binary_data();
@@ -69,6 +72,13 @@ private slots:
void cleanupTestCase();
};
+void tst_rcc::initTestCase()
+{
+ // rcc uses a QHash to store files in the resource system.
+ // we must force a certain hash order when testing or tst_rcc will fail, see QTBUG-25078
+ QVERIFY(qputenv("QT_RCC_TEST", "1"));
+}
+
QString findExpectedFile(const QString &base)
{
QString expectedrccfile = base;