Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 75d88687 authored by Laurent Montel's avatar Laurent Montel 😁

Use qputenv

parent 72ea1633
......@@ -29,8 +29,8 @@
void MessageComposer::Test::setupEnv()
{
setenv("LC_ALL", "C", 1);
setenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1("/.qttest")).constData(), 1);
qputenv("LC_ALL", "C");
qputenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1("/.qttest")).constData());
}
std::vector< GpgME::Key, std::allocator< GpgME::Key > > MessageComposer::Test::getKeys(bool smime)
......
......@@ -27,8 +27,8 @@
void MessageViewer::Test::setupEnv()
{
setenv("LC_ALL", "C", 1);
setenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1(
"/.qttest")).constData(), 1);
qputenv("LC_ALL", "C");
qputenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1(
"/.qttest")).constData());
QStandardPaths::setTestModeEnabled(true);
}
......@@ -30,9 +30,9 @@
void MessageViewer::Test::setupEnv()
{
setenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1(
"/.qttest")).constData(), 1);
setenv("TZ", "UTC", 1);
qputenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1(
"/.qttest")).constData());
qputenv("TZ", "UTC");
QStandardPaths::setTestModeEnabled(true);
QIcon::setThemeName(QStringLiteral("breeze"));
QLocale::setDefault(QLocale(QStringLiteral("en_US")));
......
......@@ -27,7 +27,7 @@
void MimeTreeParser::Test::setupEnv()
{
setenv("LC_ALL", "C", 1);
setenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1("/.qttest")).constData(), 1);
qputenv("LC_ALL", "C");
qputenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1("/.qttest")).constData());
QStandardPaths::setTestModeEnabled(true);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment