diff --git a/tests/auto/gui/itemmodels/qstandarditemmodel/CMakeLists.txt b/tests/auto/gui/itemmodels/qstandarditemmodel/CMakeLists.txt index 526102e01f..31ae25d008 100644 --- a/tests/auto/gui/itemmodels/qstandarditemmodel/CMakeLists.txt +++ b/tests/auto/gui/itemmodels/qstandarditemmodel/CMakeLists.txt @@ -20,4 +20,5 @@ qt_internal_add_test(tst_qstandarditemmodel Qt::GuiPrivate Qt::Widgets Qt::WidgetsPrivate + Qt::TestPrivate ) diff --git a/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp b/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp index 73e74b2229..f5f02761d5 100644 --- a/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp +++ b/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp @@ -10,6 +10,7 @@ #include #include +#include #include #include @@ -902,6 +903,9 @@ void tst_QStandardItemModel::sortRoleBindings() sortRoleObserver.setBinding([&] { return model.sortRole(); }); model.setSortRole(Qt::EditRole); QCOMPARE(sortRoleObserver, Qt::EditRole); + + QTestPrivate::testReadWritePropertyBasics(model, static_cast(Qt::DisplayRole), + static_cast(Qt::EditRole), "sortRole"); } void tst_QStandardItemModel::findItems()