Commit b612e9b1 authored by hjk's avatar hjk
Browse files

Debugger: Qt4/Qt5 tests



Change-Id: I210798d2cd3aa746e69d2637cc6ce51e01d5e057
Reviewed-by: default avatarhjk <hjk121@nokiamail.com>
parent 916d6b30
......@@ -42,22 +42,26 @@ using namespace Internal;
static QByteArray noValue = "\001";
struct Context
{
Context() : qtVersion(0) {}
QByteArray nameSpace;
int qtVersion;
};
struct Name
{
Name()
: name(noValue)
{}
Name(const char *str)
: name(str)
{}
Name(const QByteArray &ba)
: name(ba)
{}
bool matches(const QByteArray &actualName0, const QByteArray &nameSpace) const
Name() : name(noValue) {}
Name(const char *str) : name(str) {}
Name(const QByteArray &ba) : name(ba) {}
bool matches(const QByteArray &actualName0, const Context &context) const
{
QByteArray actualName = actualName0;
QByteArray expectedName = name;
expectedName.replace("@Q", nameSpace + 'Q');
expectedName.replace("@Q", context.nameSpace + 'Q');
return actualName == expectedName;
}
......@@ -76,28 +80,45 @@ static QByteArray parentIName(const QByteArray &iname)
return pos == -1 ? QByteArray() : iname.left(pos);
}
struct Value
struct ValueBase
{
Value()
: value(noValue), hasPtrSuffix(false)
{}
Value(const char *str)
: value(str), hasPtrSuffix(false)
{}
Value(const QByteArray &ba)
: value(ba), hasPtrSuffix(false)
{}
ValueBase() : hasPtrSuffix(false), version(0) {}
bool hasPtrSuffix;
int version;
};
struct Value : public ValueBase
{
Value() : value(noValue) {}
Value(const char *str) : value(str) {}
Value(const QByteArray &ba) : value(ba) {}
bool matches(const QString &actualValue0, const QByteArray &nameSpace) const
bool matches(const QString &actualValue0, const Context &context) const
{
if (value == noValue)
return true;
if (context.qtVersion) {
if (version == 4) {
if (context.qtVersion < 0x40000 || context.qtVersion >= 0x50000) {
//QWARN("Qt 4 specific case skipped");
return true;
}
} else if (version == 5) {
if (context.qtVersion < 0x50000 || context.qtVersion >= 0x60000) {
//QWARN("Qt 5 specific case skipped");
return true;
}
}
}
QString actualValue = actualValue0;
if (actualValue == QLatin1String(" "))
actualValue.clear(); // FIXME: Remove later.
QByteArray expectedValue = value;
expectedValue.replace('@', nameSpace);
expectedValue.replace('@', context.nameSpace);
QString self = QString::fromLatin1(expectedValue);
if (hasPtrSuffix)
return actualValue.startsWith(self + QLatin1String(" @0x"))
|| actualValue.startsWith(self + QLatin1String("@0x"));
......@@ -105,7 +126,6 @@ struct Value
}
QByteArray value;
bool hasPtrSuffix;
};
struct Pointer : Value
......@@ -114,24 +134,30 @@ struct Pointer : Value
Pointer(const QByteArray &value) : Value(value) { hasPtrSuffix = true; }
};
struct Value4 : Value
{
Value4(const QByteArray &value) : Value(value) { version = 4; }
};
struct Value5 : Value
{
Value5(const QByteArray &value) : Value(value) { version = 5; }
};
struct Type
{
Type()
{}
Type(const char *str)
: type(str)
{}
Type(const QByteArray &ba)
: type(ba)
{}
bool matches(const QByteArray &actualType0, const QByteArray &nameSpace) const
Type() {}
Type(const char *str) : type(str) {}
Type(const QByteArray &ba) : type(ba) {}
bool matches(const QByteArray &actualType0, const Context &context) const
{
QByteArray actualType =
CPlusPlus::simplifySTLType(QString::fromLatin1(actualType0)).toLatin1();
actualType.replace(' ', "");
QByteArray expectedType = type;
expectedType.replace(' ', "");
expectedType.replace('@', nameSpace);
expectedType.replace('@', context.nameSpace);
return actualType == expectedType;
}
QByteArray type;
......@@ -177,10 +203,6 @@ struct Profile
QByteArray contents;
};
struct GuiProfile : public Profile
{
GuiProfile() : Profile("QT+=gui\ngreaterThan(QT_MAJOR_VERSION, 4):QT *= widgets\n") {}
};
struct Cxx11Profile : public Profile
{
......@@ -190,14 +212,26 @@ struct Cxx11Profile : public Profile
struct ForceC {};
class Data
struct CoreProfile {};
struct CorePrivateProfile {};
struct GuiProfile {};
struct DataBase
{
DataBase() : useQt(false), forceC(false) {}
mutable bool useQt;
mutable bool forceC;
};
class Data : public DataBase
{
public:
Data() {}
Data(const QByteArray &code) : code(code), forceC(false) {}
Data(const QByteArray &code) : code(code) {}
Data(const QByteArray &includes, const QByteArray &code)
: includes(includes), code(code), forceC(false)
: includes(includes), code(code)
{}
const Data &operator%(const Check &check) const
......@@ -212,6 +246,41 @@ public:
return *this;
}
const Data &operator%(const CoreProfile &) const
{
profileExtra +=
"CONFIG += QT\n"
"QT += gui\n"
"greaterThan(QT_MAJOR_VERSION, 4):QT *= widgets\n";
useQt = true;
return *this;
}
const Data &operator%(const GuiProfile &) const
{
profileExtra +=
"CONFIG += QT\n"
"QT += gui\n"
"greaterThan(QT_MAJOR_VERSION, 4):QT *= widgets\n";
useQt = true;
return *this;
}
const Data &operator%(const CorePrivateProfile &) const
{
profileExtra +=
"CONFIG += QT\n"
"greaterThan(QT_MAJOR_VERSION, 4) {\n"
" QT += core core-private\n"
" CONFIG += no_private_qt_headers_warning\n"
"}";
useQt = true;
return *this;
}
const Data &operator%(const ForceC &) const
{
forceC = true;
......@@ -222,7 +291,6 @@ public:
mutable QByteArray profileExtra;
QByteArray includes;
QByteArray code;
mutable bool forceC;
mutable QMap<QByteArray, Check> checks;
};
......@@ -263,7 +331,10 @@ void tst_Dumpers::dumper()
proFile.write("SOURCES = ");
proFile.write(mainFile);
proFile.write("\nTARGET = doit\n");
proFile.write("QT -= widgets gui\n");
if (data.useQt)
proFile.write("QT -= widgets gui\n");
else
proFile.write("CONFIG -= QT\n");
proFile.write(data.profileExtra);
proFile.close();
......@@ -275,7 +346,8 @@ void tst_Dumpers::dumper()
"\n\n" + data.includes +
"\n\nint main(int argc, char *argv[])"
"\n{"
"\n unused(&argc, &argv);\n"
"\n int qtversion = " + (data.useQt ? "QT_VERSION" : "0") + ";\n"
"\n unused(&argc, &argv, &qtversion);\n"
"\n" + data.code +
"\n breakHere();"
"\n return 0;"
......@@ -360,10 +432,16 @@ void tst_Dumpers::dumper()
logger.write(cmds);
}
QByteArray debuggerBinary = qgetenv("QTC_DEBUGGER_PATH");
if (debuggerBinary.isEmpty())
debuggerBinary = "gdb";
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
env.insert(QLatin1String("QT_HASH_SEED"), QLatin1String("0"));
QProcess debugger;
debugger.setProcessEnvironment(env);
debugger.setWorkingDirectory(buildDir.path());
//qDebug() << "Starting debugger ";
debugger.start(QLatin1String("gdb -i mi -quiet -nx"));
debugger.start(QString::fromLatin1(debuggerBinary)
+ QLatin1String(" -i mi -quiet -nx"));
ok = debugger.waitForStarted();
debugger.write(cmds);
ok = debugger.waitForFinished();
......@@ -382,6 +460,7 @@ void tst_Dumpers::dumper()
logger.write(error);
}
Context context;
int pos1 = output.indexOf("data=");
QVERIFY(pos1 != -1);
int pos2 = output.indexOf(",typeinfo", pos1);
......@@ -394,10 +473,10 @@ void tst_Dumpers::dumper()
pos3 += sizeof("@NS@") - 1;
int pos4 = output.indexOf("@", pos3);
QVERIFY(pos4 != -1);
QByteArray nameSpace = output.mid(pos3, pos4 - pos3);
//qDebug() << "FOUND NS: " << nameSpace;
if (nameSpace == "::")
nameSpace.clear();
context.nameSpace = output.mid(pos3, pos4 - pos3);
//qDebug() << "FOUND NS: " << context.nameSpace;
if (context.nameSpace == "::")
context.nameSpace.clear();
GdbMi actual;
actual.fromString(contents);
......@@ -410,29 +489,33 @@ void tst_Dumpers::dumper()
WatchData dummy;
dummy.iname = child.findChild("iname").data();
dummy.name = QLatin1String(child.findChild("name").data());
parseWatchData(expandedINames, dummy, child, &list);
if (dummy.iname == "local.qtversion")
context.qtVersion = child.findChild("value").data().toInt();
else
parseWatchData(expandedINames, dummy, child, &list);
}
//qDebug() << "QT VERSION " << QByteArray::number(context.qtVersion, 16);
QSet<QByteArray> seenINames;
foreach (const WatchData &item, list) {
seenINames.insert(item.iname);
if (data.checks.contains(item.iname)) {
Check check = data.checks.take(item.iname);
if (!check.expectedName.matches(item.name.toLatin1(), nameSpace)) {
if (!check.expectedName.matches(item.name.toLatin1(), context)) {
qDebug() << "INAME : " << item.iname;
qDebug() << "NAME ACTUAL : " << item.name.toLatin1();
qDebug() << "NAME EXPECTED: " << check.expectedName.name;
qDebug() << "CONTENTS : " << contents;
QVERIFY(false);
}
if (!check.expectedValue.matches(item.value, nameSpace)) {
if (!check.expectedValue.matches(item.value, context)) {
qDebug() << "INAME : " << item.iname;
qDebug() << "VALUE ACTUAL : " << item.value << item.value.toLatin1().toHex();
qDebug() << "VALUE EXPECTED: " << check.expectedValue.value << check.expectedValue.value.toHex();
qDebug() << "CONTENTS : " << contents;
QVERIFY(false);
}
if (!check.expectedType.matches(item.type, nameSpace)) {
if (!check.expectedType.matches(item.type, context)) {
qDebug() << "INAME : " << item.iname;
qDebug() << "TYPE ACTUAL : " << item.type;
qDebug() << "TYPE EXPECTED: " << check.expectedType.type;
......@@ -443,9 +526,13 @@ void tst_Dumpers::dumper()
}
if (!data.checks.isEmpty()) {
bool fail = false;
qDebug() << "SOME TESTS NOT EXECUTED: ";
foreach (const Check &check, data.checks)
foreach (const Check &check, data.checks) {
qDebug() << " TEST NOT FOUND FOR INAME: " << check.iname;
if (!fail && check.expectedValue.version != 0)
fail = true;
}
qDebug() << "SEEN INAMES " << seenINames;
qDebug() << "CONTENTS : " << contents;
qDebug() << "EXPANDED : " << expanded;
......@@ -514,6 +601,7 @@ void tst_Dumpers::dumper_data()
QTest::newRow("QByteArray0")
<< Data("#include <QByteArray>\n",
"QByteArray ba;")
% CoreProfile()
% Check("ba", "ba", "\"\"", "@QByteArray");
QTest::newRow("QByteArray1")
......@@ -522,6 +610,7 @@ void tst_Dumpers::dumper_data()
"ba += char(0);\n"
"ba += 1;\n"
"ba += 2;\n")
% CoreProfile()
% Check("ba", "\"Hello\"World\"", "@QByteArray")
% Check("ba.0", "[0]", "72", "char")
% Check("ba.11", "[11]", "0", "char")
......@@ -538,6 +627,7 @@ void tst_Dumpers::dumper_data()
"QString s(10000, 'x');\n"
"std::string ss(10000, 'c');\n"
"unused(&ba, &s, &ss);\n")
% CoreProfile()
% CheckType("ba", "@QByteArray")
% Check("s", '"' + QByteArray(10000, 'x') + '"', "@QString")
% Check("ss", '"' + QByteArray(10000, 'c') + '"', "std::string");
......@@ -551,6 +641,7 @@ void tst_Dumpers::dumper_data()
"QByteArray buf2(str2);\n"
"QByteArray buf3(str3);\n"
"unused(&buf1, &buf2, &buf3);\n")
% CoreProfile()
% Check("buf1", "\"" + QByteArray(1, 0xee) + "\"", "@QByteArray")
% Check("buf2", "\"" + QByteArray(1, 0xee) + "\"", "@QByteArray")
% Check("buf3", "\"\ee\"", "@QByteArray")
......@@ -561,6 +652,7 @@ void tst_Dumpers::dumper_data()
"char data[] = { 'H', 'e', 'l', 'l', 'o' };\n"
"QByteArray ba1 = QByteArray::fromRawData(data, 4);\n"
"QByteArray ba2 = QByteArray::fromRawData(data + 1, 4);\n")
% CoreProfile()
% Check("ba1", "\"Hell\"", "@QByteArray")
% Check("ba2", "\"ello\"", "@QByteArray");
......@@ -568,13 +660,16 @@ void tst_Dumpers::dumper_data()
<< Data("#include <QDate>\n",
"QDate date;\n"
"unused(&date);\n")
% Check("date", "(invalid)", "@QDate");
% CoreProfile()
% Check("date", Value4("(invalid)"), "@QDate")
% Check("date", Value5(""), "@QDate");
QTest::newRow("QDate1")
<< Data("#include <QDate>\n",
"QDate date;\n"
"date.setDate(1980, 1, 1);\n"
"unused(&date);\n")
% CoreProfile()
% Check("date", "Tue Jan 1 1980", "@QDate")
% Check("date.(ISO)", "\"1980-01-01\"", "@QString")
% CheckType("date.(Locale)", "@QString")
......@@ -584,11 +679,13 @@ void tst_Dumpers::dumper_data()
QTest::newRow("QTime0")
<< Data("#include <QTime>\n",
"QTime time;\n")
% CoreProfile()
% Check("time", "(invalid)", "@QTime");
QTest::newRow("QTime1")
<< Data("#include <QTime>\n",
"QTime time(13, 15, 32);")
% CoreProfile()
% Check("time", "13:15:32", "@QTime")
% Check("time.(ISO)", "\"13:15:32\"", "@QString")
% CheckType("time.(Locale)", "@QString")
......@@ -598,11 +695,13 @@ void tst_Dumpers::dumper_data()
QTest::newRow("QDateTime0")
<< Data("#include <QDateTime>\n",
"QDateTime date;\n")
% CoreProfile()
% Check("date", "(invalid)", "@QDateTime");
QTest::newRow("QDateTime1")
<< Data("#include <QDateTime>\n",
"QDateTime date(QDate(1980, 1, 1), QTime(13, 15, 32), Qt::UTC);\n")
% CoreProfile()
% Check("date", "Tue Jan 1 13:15:32 1980", "@QDateTime")
% Check("date.(ISO)", "\"1980-01-01T13:15:32Z\"", "@QString")
% CheckType("date.(Locale)", "@QString")
......@@ -620,6 +719,7 @@ void tst_Dumpers::dumper_data()
"QDir dir(" + tempDir + ");\n"
"QString s = dir.absolutePath();\n"
"unused(&dir, &s);\n")
% CoreProfile()
% Check("dir", tempDir, "@QDir")
% Check("dir.absolutePath", tempDir, "@QString")
% Check("dir.canonicalPath", tempDir, "@QString");
......@@ -642,25 +742,32 @@ void tst_Dumpers::dumper_data()
"file.setObjectName(\"A QFile instance\");\n"
"QFileInfo fi(\"/tmp/tt\");\n"
"QString s = fi.absoluteFilePath();\n")
% CoreProfile()
% Check("fi", "\"/tmp/tt\"", "@QFileInfo")
% Check("file", "\"/tmp/t\"", "@QFile")
% Check("s", "\"/tmp/tt\"", "@QString");
#endif
QTest::newRow("QHash1")
<< Data("#include <QHash>\n",
<< Data("#include <QHash>\n"
"#include <QString>\n"
"#include <QList>\n",
"QHash<QString, QList<int> > hash;\n"
"hash.insert(\"Hallo\", QList<int>());\n"
"hash.insert(\"Welt\", QList<int>() << 1);\n"
"hash.insert(\"!\", QList<int>() << 1 << 2);\n")
% CoreProfile()
% Check("hash", "<3 items>", "@QHash<@QString, @QList<int> >")
% Check("hash.0", "[0]", "", "@QHashNode<@QString, @QList<int>>")
% Check("hash.0.key", "\"Hallo\"", "@QString")
% Check("hash.0.value", "<0 items>", "@QList<int>")
% Check("hash.0.key", Value4("\"Hallo\""), "@QString")
% Check("hash.0.key", Value5("\"Welt\""), "@QString")
% Check("hash.0.value", Value4("<0 items>"), "@QList<int>")
% Check("hash.0.value", Value5("<1 items>"), "@QList<int>")
% Check("hash.1", "[1]", "", "@QHashNode<@QString, @QList<int>>")
% Check("hash.1.key", "key", "\"Welt\"", "@QString")
% Check("hash.1.value", "value", "<1 items>", "@QList<int>")
% Check("hash.1.value.0", "[0]", "1", "int")
% Check("hash.1.key", "key", Value4("\"Welt\""), "@QString")
% Check("hash.1.key", "key", Value5("\"Hallo\""), "@QString")
% Check("hash.1.value", "value", Value4("<1 items>"), "@QList<int>")
% Check("hash.1.value", "value", Value5("<0 items>"), "@QList<int>")
% Check("hash.2", "[2]", "", "@QHashNode<@QString, @QList<int>>")
% Check("hash.2.key", "key", "\"!\"", "@QString")
% Check("hash.2.value", "value", "<2 items>", "@QList<int>")
......@@ -672,12 +779,14 @@ void tst_Dumpers::dumper_data()
"QHash<int, float> hash;\n"
"hash[11] = 11.0;\n"
"hash[22] = 22.0;\n")
% CoreProfile()
% Check("hash", "hash", "<2 items>", "@QHash<int, float>")
% Check("hash.22", "[22]", "22", "float")
% Check("hash.11", "[11]", "11", "float");
QTest::newRow("QHash3")
<< Data("#include <QHash>\n",
<< Data("#include <QString>\n"
"#include <QHash>\n",
"QHash<QString, int> hash;\n"
"hash[\"22.0\"] = 22.0;\n"
"hash[\"123.0\"] = 22.0;\n"
......@@ -688,16 +797,22 @@ void tst_Dumpers::dumper_data()
"hash[\"111111127.0\"] = 27.0;\n"
"hash[\"111111111128.0\"] = 28.0;\n"
"hash[\"111111111111111111129.0\"] = 29.0;\n")
% CoreProfile()
% Check("hash", "hash", "<9 items>", "@QHash<@QString, int>")
% Check("hash.0", "[0]", "", "@QHashNode<@QString, int>")
% Check("hash.0.key", "key", "\"123.0\"", "@QString")
% Check("hash.0.value", "22", "int")
% Check("hash.0.key", "key", Value4("\"123.0\""), "@QString")
% Check("hash.0.key", "key", Value5("\"111111111128.0\""), "@QString")
% Check("hash.0.value", Value4("22"), "int")
% Check("hash.0.value", Value5("28"), "int")
% Check("hash.8", "[8]", "", "@QHashNode<@QString, int>")
% Check("hash.8.key", "key", "\"11124.0\"", "@QString")
% Check("hash.8.value", "value", "22", "int");
% Check("hash.8.key", "key", Value4("\"11124.0\""), "@QString")
% Check("hash.8.key", "key", Value5("\"123.0\""), "@QString")
% Check("hash.8.value", "value", Value4("22"), "int")
% Check("hash.8.value", "value", Value5("22"), "int");
QTest::newRow("QHash4")
<< Data("#include <QHash>\n",
<< Data("#include <QByteArray>\n"
"#include <QHash>\n",
"QHash<QByteArray, float> hash;\n"
"hash[\"22.0\"] = 22.0;\n"
"hash[\"123.0\"] = 22.0;\n"
......@@ -708,18 +823,25 @@ void tst_Dumpers::dumper_data()
"hash[\"111111127.0\"] = 27.0;\n"
"hash[\"111111111128.0\"] = 28.0;\n"
"hash[\"111111111111111111129.0\"] = 29.0;\n")
% CoreProfile()
% Check("hash", "<9 items>", "@QHash<@QByteArray, float>")
% Check("hash.0", "[0]", "", "@QHashNode<@QByteArray, float>")
% Check("hash.0.key", "\"123.0\"", "@QByteArray")
% Check("hash.0.value", "22", "float")
% Check("hash.0.key", Value4("\"123.0\""), "@QByteArray")
% Check("hash.0.key", Value5("\"111111111128.0\""), "@QByteArray")
% Check("hash.0.value", Value4("22"), "float")
% Check("hash.0.value", Value5("28"), "float")
% Check("hash.8", "[8]", "", "@QHashNode<@QByteArray, float>")
% Check("hash.8.key", "\"11124.0\"", "@QByteArray")
% Check("hash.8.value", "22", "float");
% Check("hash.8.key", Value4("\"11124.0\""), "@QByteArray")
% Check("hash.8.key", Value5("\"123.0\""), "@QByteArray")
% Check("hash.8.value", Value4("22"), "float")
% Check("hash.8.value", Value5("22"), "float");
QTest::newRow("QHash5")
<< Data("#include <QHash>\n",
<< Data("#include <QString>\n"
"#include <QHash>\n",
"QHash<int, QString> hash;\n"
"hash[22] = \"22.0\";\n")
% CoreProfile()
% Check("hash", "<1 items>", "@QHash<int, @QString>")
% Check("hash.0", "[0]", "", "@QHashNode<int, @QString>")
% Check("hash.0.key", "22", "int")
......@@ -730,13 +852,17 @@ void tst_Dumpers::dumper_data()
"QHash<QString, Foo> hash;\n"
"hash[\"22.0\"] = Foo(22);\n"
"hash[\"33.0\"] = Foo(33);\n")
% CoreProfile()
% Check("hash", "<2 items>", "@QHash<@QString, Foo>")
% Check("hash.0", "[0]", "", "@QHashNode<@QString, Foo>")
% Check("hash.0.key", "\"22.0\"", "@QString")
% Check("hash.0.key", Value4("\"22.0\""), "@QString")
% Check("hash.0.key", Value5("\"33.0\""), "@QString")
% CheckType("hash.0.value", "Foo")
% Check("hash.0.value.a", "22", "int")
% Check("hash.0.value.a", Value4("22"), "int")
% Check("hash.0.value.a", Value5("33"), "int")
% Check("hash.1", "[1]", "", "@QHashNode<@QString, Foo>")
% Check("hash.1.key", "\"33.0\"", "@QString")
% Check("hash.1.key", Value4("\"33.0\""), "@QString")
% Check("hash.1.key", Value4("\"22.0\""), "@QString")
% CheckType("hash.1.value", "Foo");
QTest::newRow("QHash7")
......@@ -747,11 +873,13 @@ void tst_Dumpers::dumper_data()
"hash.insert(\"Hallo\", QPointer<QObject>(&ob));\n"
"hash.insert(\"Welt\", QPointer<QObject>(&ob));\n"
"hash.insert(\".\", QPointer<QObject>(&ob));\n")
% CoreProfile()
% Check("hash", "<3 items>", "@QHash<@QString, @QPointer<@QObject>>")
% Check("hash.0", "[0]", "", "@QHashNode<@QString, @QPointer<@QObject>>")
% Check("hash.0.key", "\"Hallo\"", "@QString")
% Check("hash.0.key", Value4("\"Hallo\""), "@QString")
% Check("hash.0.key", Value4("\"Welt\""), "@QString")
% CheckType("hash.0.value", "@QPointer<@QObject>")
% CheckType("hash.0.value.o", "@QObject")
//% CheckType("hash.0.value.o", "@QObject")
% Check("hash.2", "[2]", "", "@QHashNode<@QString, @QPointer<@QObject>>")
% Check("hash.2.key", "\".\"", "@QString")
% CheckType("hash.2.value", "@QPointer<@QObject>");
......@@ -772,6 +900,7 @@ void tst_Dumpers::dumper_data()
"Hash::iterator it4 = it3; ++it4;\n"
"Hash::iterator it5 = it4; ++it5;\n"
"Hash::iterator it6 = it5; ++it6;\n")
% CoreProfile()
% Check("hash", "<6 items>", "Hash")
% Check("hash.11", "[11]", "11", "float")
% Check("it1.key", "55", "int")
......@@ -783,6 +912,7 @@ void tst_Dumpers::dumper_data()
<< Data("#include <QHostAddress>\n",
"QHostAddress ha1(129u * 256u * 256u * 256u + 130u);\n"
"QHostAddress ha2(\"127.0.0.1\");\n")
% CoreProfile()
% Profile("QT += network\n")
% Check("ha1", "129.0.0.130", "@QHostAddress")
% Check("ha2", "\"127.0.0.1\"", "@QHostAddress");
......@@ -793,7 +923,8 @@ void tst_Dumpers::dumper_data()