Turn a comment in a test into an actual check
Saying the code should produce no warnings is all well and good, but testing it produces no warnings is obviously better. Pick-to: 6.8 6.5 Change-Id: Iafa82027fde9ef6c7157b42ff3bbcccb3d097230 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> (cherry picked from commit 0b67d446566005e6409f816a6f223f26ef1994ca) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
26cda01b29
commit
103a636e00
@ -3874,7 +3874,7 @@ void tst_QDateTime::printNegativeYear() const
|
||||
#if QT_CONFIG(datetimeparser)
|
||||
void tst_QDateTime::roundtripTextDate() const
|
||||
{
|
||||
/* This code path should not result in warnings. */
|
||||
QTest::failOnWarning(); // This code path should not result in warnings.
|
||||
const QDateTime now(QDateTime::currentDateTime());
|
||||
// TextDate drops millis:
|
||||
const QDateTime theDateTime(now.addMSecs(-now.time().msec()));
|
||||
|
Loading…
x
Reference in New Issue
Block a user