diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/installer/brokeninstaller/tst_brokeninstaller.cpp | 6 | ||||
-rw-r--r-- | tests/auto/installer/componentmodel/tst_componentmodel.cpp | 24 |
2 files changed, 15 insertions, 15 deletions
diff --git a/tests/auto/installer/brokeninstaller/tst_brokeninstaller.cpp b/tests/auto/installer/brokeninstaller/tst_brokeninstaller.cpp index 95f4ac77d..43bd15288 100644 --- a/tests/auto/installer/brokeninstaller/tst_brokeninstaller.cpp +++ b/tests/auto/installer/brokeninstaller/tst_brokeninstaller.cpp @@ -100,7 +100,7 @@ private slots: QList<Component*> rootComponents = loadComponents(core); ComponentModel *model = new ComponentModel(1, &core); - model->setRootComponents(rootComponents); + model->reset(rootComponents); // all names should be resolvable QStringList all; all << m_checkedComponentsWithBrokenScript << m_uncheckedComponentsWithBrokenScript << m_partiallyCheckedComponentsWithBrokenScript; @@ -127,7 +127,7 @@ private slots: QTest::ignoreMessage(QtWarningMsg, re); invalidScriptComponent->loadComponentScript(":///data/broken_script.qs"); - model->setRootComponents(components); + model->reset(components); testModelState(model, m_checkedComponentsWithBrokenScript, m_partiallyCheckedComponentsWithBrokenScript, m_uncheckedComponentsWithBrokenScript); } @@ -146,7 +146,7 @@ private slots: componentDependingOnMissingDependency->addDependency("componentmissingdependency"); core.componentsToInstallNeedsRecalculation(); - model->setRootComponents(components); + model->reset(components); testModelState(model, m_checkedComponentsWithMissingDependency, m_partiallyCheckedComponentsWithBrokenScript, m_uncheckedComponentsWithMissingDependency); } diff --git a/tests/auto/installer/componentmodel/tst_componentmodel.cpp b/tests/auto/installer/componentmodel/tst_componentmodel.cpp index 3aef34fe4..463485d96 100644 --- a/tests/auto/installer/componentmodel/tst_componentmodel.cpp +++ b/tests/auto/installer/componentmodel/tst_componentmodel.cpp @@ -92,7 +92,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); // all names should be resolvable, virtual components are not indexed if they are not visible QStringList all; @@ -116,7 +116,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); // all names should be resolvable, including virtual components QStringList all; @@ -141,7 +141,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); QCOMPARE(model.core(), &m_core); @@ -162,7 +162,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); QCOMPARE(model.checkedState(), ComponentModel::DefaultChecked); @@ -184,7 +184,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); QCOMPARE(model.checkedState(), ComponentModel::DefaultChecked); @@ -204,7 +204,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); QCOMPARE(model.checkedState(), ComponentModel::DefaultChecked); @@ -226,7 +226,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); // select all possible components. @@ -262,7 +262,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); // select all possible components. @@ -300,7 +300,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); // select all possible components. @@ -335,7 +335,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); // select all possible components. @@ -379,7 +379,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); const QModelIndex root = model.indexFromComponentName(vendorProduct); QCOMPARE(model.data(root, Qt::DisplayRole).toString(), expectedName); @@ -397,7 +397,7 @@ private slots: // setup the model with 1 column ComponentModel model(1, &m_core); - model.setRootComponents(rootComponents); + model.reset(rootComponents); testDefaultInheritedModelBehavior(&model, 1); model.setCheckedState(ComponentModel::DefaultChecked); |