Workaround, to debug XGUI_DataModel and Model connection later to see why the model index is not valid and leads to crash.
SessionPtr aMgr = ModelAPI_Session::get();
DocumentPtr aActiveDoc = aMgr->activeDocument();
- if (myActivePartIndex.isValid())
- aTreeView->setExpanded(myActivePartIndex, false);
+ // workaround for #2431 (SISGSEGV when launching some unit tests from GUI)
+ //if (myActivePartIndex.isValid())
+ // aTreeView->setExpanded(myActivePartIndex, false);
XGUI_DataModel* aDataModel = aWorkshop->objectBrowser()->dataModel();
myActivePartIndex = aDataModel->documentRootIndex(aActiveDoc, 0);