Changeset View
Changeset View
Standalone View
Standalone View
libtaskmanager/autotests/tasktoolstest.cpp
Show First 20 Lines • Show All 60 Lines • ▼ Show 20 Line(s) | 57 | private: | |||
---|---|---|---|---|---|
61 | void createIcon(); | 61 | void createIcon(); | ||
62 | 62 | | |||
63 | AppData m_referenceAppData; | 63 | AppData m_referenceAppData; | ||
64 | QTemporaryDir m_tempDir; | 64 | QTemporaryDir m_tempDir; | ||
65 | }; | 65 | }; | ||
66 | 66 | | |||
67 | void TaskToolsTest::initTestCase() | 67 | void TaskToolsTest::initTestCase() | ||
68 | { | 68 | { | ||
69 | QStandardPaths::enableTestMode(true); | 69 | QStandardPaths::setTestModeEnabled(true); | ||
70 | 70 | | |||
71 | QVERIFY(m_tempDir.isValid()); | 71 | QVERIFY(m_tempDir.isValid()); | ||
72 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/config"))); | 72 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/config"))); | ||
73 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/cache"))); | 73 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/cache"))); | ||
74 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/data/applications"))); | 74 | QVERIFY(QDir().mkpath(m_tempDir.path() + QLatin1String("/data/applications"))); | ||
75 | 75 | | |||
76 | #ifdef Q_XDG_PLATFORM | 76 | #ifdef Q_XDG_PLATFORM | ||
77 | qputenv("XDG_CONFIG_HOME", QFile::encodeName(m_tempDir.path() + QLatin1String("/config"))); | 77 | qputenv("XDG_CONFIG_HOME", QFile::encodeName(m_tempDir.path() + QLatin1String("/config"))); | ||
▲ Show 20 Lines • Show All 137 Lines • Show Last 20 Lines |