Only refresh project tree values when status labels change
This commit is contained in:
@@ -221,7 +221,7 @@ def testGuiViewerPanel_Tags(qtbot, monkeypatch, caplog, nwGUI, projPath, mockRnd
|
||||
nwJohn = SHARED.project.tree[hJohn]
|
||||
assert isinstance(nwJohn, NWItem)
|
||||
nwJohn.setActive(False)
|
||||
projTree.setTreeItemValues(hJohn)
|
||||
projTree.setTreeItemValues(nwJohn)
|
||||
projTree._alertTreeChange(hJohn, flush=False)
|
||||
assert charTab.topLevelItemCount() == 1
|
||||
|
||||
|
||||
@@ -186,6 +186,10 @@ def testGuiProjTree_NewItems(qtbot, caplog, monkeypatch, nwGUI, projPath, mockRn
|
||||
# Adding an invalid item directly to the tree should also fail
|
||||
assert projTree._addTreeItem(None) is None
|
||||
|
||||
# Setting values for a non-existing tree item should be handled
|
||||
projTree.setTreeItemValues(None)
|
||||
projTree.setTreeItemValues(C.hInvalid) # The function used to take handles
|
||||
|
||||
# Clean up
|
||||
# qtbot.stop()
|
||||
nwGUI.closeProject()
|
||||
|
||||
Reference in New Issue
Block a user