forked from qt-creator/qt-creator
AutoTest: Fix enabled state of framework root
Do not evaluate the invisible root as it is not a real test tree item. Change-Id: I944c1ac2f8ed3ff47cd8036ebf8fd8319e05e1ab Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -337,6 +337,9 @@ bool BoostTestTreeItem::enabled() const
|
|||||||
if (m_state & Disabled)
|
if (m_state & Disabled)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
if (type() == Root)
|
||||||
|
return true;
|
||||||
|
|
||||||
const TestTreeItem *parent = parentItem();
|
const TestTreeItem *parent = parentItem();
|
||||||
if (parent && parent->type() == TestSuite) // take test suites into account
|
if (parent && parent->type() == TestSuite) // take test suites into account
|
||||||
return static_cast<const BoostTestTreeItem *>(parent)->enabled();
|
return static_cast<const BoostTestTreeItem *>(parent)->enabled();
|
||||||
|
|||||||
Reference in New Issue
Block a user