Skip to content

Commit

Permalink
Make declarative/creation benchmark build again
Browse files Browse the repository at this point in the history
Change-Id: I9ecbdcfc373e95de38e432aa627f6ab93d92afe6
Reviewed-on: http://codereview.qt-project.org/5138
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
  • Loading branch information
Kent Hansen authored and Qt by Nokia committed Sep 19, 2011
1 parent 8de9a07 commit 0c9e558
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion tests/benchmarks/declarative/creation/creation.pro
@@ -1,7 +1,7 @@
load(qttest_p4)
TEMPLATE = app
TARGET = tst_creation
QT += declarative qtquick1
QT += declarative qtquick1 widgets
macx:CONFIG -= app_bundle

SOURCES += tst_creation.cpp
Expand Down
11 changes: 6 additions & 5 deletions tests/benchmarks/declarative/creation/tst_creation.cpp
Expand Up @@ -264,6 +264,7 @@ void tst_creation::itemtree_notree_cpp()
QDeclarativeItem *item = new QDeclarativeItem;
for (int i = 0; i < 30; ++i) {
QDeclarativeItem *child = new QDeclarativeItem;
Q_UNUSED(child);
}
delete item;
}
Expand Down Expand Up @@ -340,16 +341,16 @@ void tst_creation::itemtree_scene_cpp()

void tst_creation::elements_data()
{
QTest::addColumn<QByteArray>("type");
QTest::addColumn<QString>("type");

QList<QByteArray> types = QDeclarativeMetaType::qmlTypeNames();
foreach (QByteArray type, types)
QTest::newRow(type.constData()) << type;
QList<QString> types = QDeclarativeMetaType::qmlTypeNames();
foreach (QString type, types)
QTest::newRow(type.toLatin1()) << type;
}

void tst_creation::elements()
{
QFETCH(QByteArray, type);
QFETCH(QString, type);
QDeclarativeType *t = QDeclarativeMetaType::qmlType(type, 2, 0);
if (!t || !t->isCreatable())
QSKIP("Non-creatable type", SkipSingle);
Expand Down

0 comments on commit 0c9e558

Please sign in to comment.