summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSandro Knauß <[email protected]>2017-11-22 15:45:37 +0100
committerSandro Knauß <[email protected]>2017-11-22 15:52:10 +0100
commitb299d7b8095d1e00268070df9d250dad98c23ffe (patch)
tree1745b74ca9d641868a12d73cd3d30ce405436904
parentee05dd4ae1bd983ff5ef9b944f020f8c4f8393ac (diff)
fix tests on CI (hopefully).
use breeze icon theme ( cause we can't expect oxygen to be available).
-rw-r--r--plugins/messageviewer/bodypartformatter/autotests/data/attached-vcard.mbox.html2
-rw-r--r--plugins/messageviewer/bodypartformatter/autotests/data/tnef-one-file.mbox.html2
-rw-r--r--plugins/messageviewer/bodypartformatter/autotests/data/tnef-two-files.mbox.html4
-rw-r--r--plugins/messageviewer/bodypartformatter/autotests/rendertest.cpp7
4 files changed, 9 insertions, 6 deletions
diff --git a/plugins/messageviewer/bodypartformatter/autotests/data/attached-vcard.mbox.html b/plugins/messageviewer/bodypartformatter/autotests/data/attached-vcard.mbox.html
index fd3b253..ff05dd8 100644
--- a/plugins/messageviewer/bodypartformatter/autotests/data/attached-vcard.mbox.html
+++ b/plugins/messageviewer/bodypartformatter/autotests/data/attached-vcard.mbox.html
@@ -18,7 +18,7 @@
<table cellpadding="3" cellspacing="1">
<tr>
<td align="right" valign="top" width="30%" rowspan="3">
- <img src="file:user-identity.png" width="100" vspace="1"/>
+ <img src="file:user-identity.svg" width="100" vspace="1"/>
</td>
<td colspan="2" align="left" width="70%">
<font size="+2">
diff --git a/plugins/messageviewer/bodypartformatter/autotests/data/tnef-one-file.mbox.html b/plugins/messageviewer/bodypartformatter/autotests/data/tnef-one-file.mbox.html
index 9f555cf..92b10d3 100644
--- a/plugins/messageviewer/bodypartformatter/autotests/data/tnef-one-file.mbox.html
+++ b/plugins/messageviewer/bodypartformatter/autotests/data/tnef-one-file.mbox.html
@@ -20,7 +20,7 @@
<tr class="textAtmB">
<td>
<div>
- <a href="file:AUTHORS"><img src="file:application-octet-stream.png" border="0" style="max-width: 100%"/>AUTHORS file for tnef</a>
+ <a href="file:AUTHORS"><img src="file:application-octet-stream.svg" border="0" style="max-width: 100%"/>AUTHORS file for tnef</a>
</div>
<br/>
</td>
diff --git a/plugins/messageviewer/bodypartformatter/autotests/data/tnef-two-files.mbox.html b/plugins/messageviewer/bodypartformatter/autotests/data/tnef-two-files.mbox.html
index e813166..17063f2 100644
--- a/plugins/messageviewer/bodypartformatter/autotests/data/tnef-two-files.mbox.html
+++ b/plugins/messageviewer/bodypartformatter/autotests/data/tnef-two-files.mbox.html
@@ -20,11 +20,11 @@
<tr class="textAtmB">
<td>
<div>
- <a href="file:AUTHORS"><img src="file:application-octet-stream.png" border="0" style="max-width: 100%"/>AUTHORS file for tnef</a>
+ <a href="file:AUTHORS"><img src="file:application-octet-stream.svg" border="0" style="max-width: 100%"/>AUTHORS file for tnef</a>
</div>
<br/>
<div>
- <a href="file:README"><img src="file:application-octet-stream.png" border="0" style="max-width: 100%"/>README file for tnef</a>
+ <a href="file:README"><img src="file:application-octet-stream.svg" border="0" style="max-width: 100%"/>README file for tnef</a>
</div>
<br/>
</td>
diff --git a/plugins/messageviewer/bodypartformatter/autotests/rendertest.cpp b/plugins/messageviewer/bodypartformatter/autotests/rendertest.cpp
index e7cdb01..743e974 100644
--- a/plugins/messageviewer/bodypartformatter/autotests/rendertest.cpp
+++ b/plugins/messageviewer/bodypartformatter/autotests/rendertest.cpp
@@ -36,8 +36,13 @@
#ifndef Q_OS_WIN
void initLocale()
{
+ setenv("KDEHOME", QFile::encodeName(QDir::homePath() + QString::fromLatin1(
+ "/.qttest")).constData(), 1);
setenv("LC_ALL", "en_US.utf-8", 1);
+ setenv("TZ", "UTC", 1);
QStandardPaths::setTestModeEnabled(true);
+ QIcon::setThemeName(QStringLiteral("breeze"));
+ QLocale::setDefault(QLocale(QStringLiteral("en_US")));
}
Q_CONSTRUCTOR_FUNCTION(initLocale)
@@ -66,8 +71,6 @@ void RenderTest::testRender()
QFETCH(QString, referenceFileName);
QFETCH(QString, outFileName);
- QIcon::setThemeName(QStringLiteral("oxygen"));
-
// load input mail
QFile mailFile(mailFileName);
QVERIFY(mailFile.open(QIODevice::ReadOnly));