blob: 4f63e8c99520b8382e0364d25ea85e685d80c51b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
// Copyright (C) 2018 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#include <QTest>
class tst_FailDataType: public QObject
{
Q_OBJECT
private slots:
void value_data() const;
void value() const;
};
void tst_FailDataType::value_data() const
{
QTest::addColumn<QString>("value");
QTest::newRow("bool-as-string") << true; // assertion should fail here
}
/*! \internal
This function should never be run because its _data() fails.
*/
void tst_FailDataType::value() const
{
QFAIL("ERROR: this function is NOT supposed to be run.");
}
QTEST_APPLESS_MAIN(tst_FailDataType)
#include "tst_faildatatype.moc"
|