Try to fix test for automatic run with travis

* Additionally calculate valid pressure
This commit is contained in:
2017-02-13 21:04:03 +03:00
parent d097e154ff
commit 10f556e41b
8 changed files with 54 additions and 17 deletions

View File

@ -93,8 +93,9 @@ YahooWeatherProvider::parseCurrent(const QVariantMap &json,
= json[QString("condition")].toMap()[QString("date")].toString();
values[QString("humidity%1").arg(number())]
= atmosphere[QString("humidity")].toInt();
// HACK temporary fix of invalid values on Yahoo! side
values[QString("pressure%1").arg(number())]
= static_cast<int>(atmosphere[QString("pressure")].toFloat());
= static_cast<int>(atmosphere[QString("pressure")].toFloat() / 33.863753);
return values;
}