Skip to content

Commit dca998f

Browse files
committed
Show anomaly hashes in test reporting
1 parent 60f7b7d commit dca998f

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/src/core/qgsrenderchecker.cpp

+9
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ bool QgsRenderChecker::isKnownAnomaly( QImage theDifferenceImage )
6969
theDifferenceImage.numBytes());
7070
QByteArray mySourceHash = QCryptographicHash::hash(
7171
myData, QCryptographicHash::Md5);
72+
7273
for (int i = 0; i < myList.size(); ++i)
7374
{
7475
QString myFile = myList.at(i);
@@ -80,6 +81,14 @@ bool QgsRenderChecker::isKnownAnomaly( QImage theDifferenceImage )
8081
myAnomalyImage.numBytes());
8182
QByteArray myAnomolyHash = QCryptographicHash::hash(
8283
myData, QCryptographicHash::Md5);
84+
QString myHashMessage = QString("Source image hash %1 : Anomaly hash: %2").arg(
85+
QString(mySourceHash.toHex())).arg(QString(myAnomolyHash.toHex()));
86+
//fro CDash
87+
QString myMeasureMessage = "<DartMeasurement name=\"Anomoly check"
88+
"\" type=\"text/text\">" + myHashMessage +
89+
"</DartMeasurement>";
90+
qDebug() << myMeasureMessage;
91+
mReport += "<tr><td colspan=3>" + myHashMessage + "</td></tr>";
8392
if ( mySourceHash.toHex() == myAnomolyHash.toHex() )
8493
{
8594
mReport += "<tr><td colspan=3>"

0 commit comments

Comments
 (0)