Update tests and remove unused functions in viewer

This commit is contained in:
Veronica Berglyd Olsen
2022-11-15 16:50:41 +01:00
parent a2ea7b40e2
commit e0ca2e7fb5
5 changed files with 24 additions and 71 deletions
-11
View File
@@ -515,17 +515,6 @@ def testGuiMain_Editing(qtbot, monkeypatch, nwGUI, projPath, tstPaths, mockRnd):
assert nwGUI.saveProject()
assert nwGUI.closeDocViewer()
# Check a Quick Create and Delete
assert nwGUI.projView.projTree.newTreeItem(nwItemType.FILE, None)
newHandle = nwGUI.projView.getSelectedHandle()
assert newHandle == "0000000000013"
assert nwGUI.theProject.tree[newHandle] is not None
assert nwGUI.projView.requestDeleteItem()
assert nwGUI.projView.setSelectedHandle(newHandle)
assert nwGUI.projView.requestDeleteItem()
assert nwGUI.theProject.tree["0000000000014"] is not None # Trash
assert nwGUI.saveProject()
# Check the files
projFile = projPath / "nwProject.nwx"
testFile = tstPaths.outDir / "guiEditor_Main_Final_nwProject.nwx"