Fix current tests

This commit is contained in:
Veronica Berglyd Olsen
2025-06-12 19:22:11 +02:00
parent ff85c6688f
commit e3eea2628a
23 changed files with 380 additions and 303 deletions
+12 -12
View File
@@ -214,22 +214,22 @@ def testDlgProjSettings_StatusImport(qtbot, monkeypatch, nwGUI, projPath, mockRn
assert update[0][0] == C.sNew
assert update[0][1].name == "New"
assert update[0][1].color == QColor(120, 120, 120)
assert update[0][1].color.getRgb() == (108, 108, 108, 255)
assert update[0][1].shape == nwStatusShape.STAR
assert update[1][0] == C.sDraft
assert update[1][1].name == "Draft"
assert update[1][1].color == QColor(143, 240, 164)
assert update[1][1].color.getRgb() == (163, 156, 52, 255)
assert update[1][1].shape == nwStatusShape.CIRCLE_T
assert update[2][0] == C.sFinished
assert update[2][1].name == "Finished"
assert update[2][1].color == QColor(249, 240, 107)
assert update[2][1].color.getRgb() == (41, 102, 41, 255)
assert update[2][1].shape == nwStatusShape.STAR
assert update[3][0] is None
assert update[3][1].name == "Final"
assert update[3][1].color == QColor(20, 30, 40)
assert update[3][1].color.getRgb() == (20, 30, 40, 255)
assert update[3][1].shape == nwStatusShape.CIRCLE
# Move items, none selected -> no change
@@ -289,22 +289,22 @@ def testDlgProjSettings_StatusImport(qtbot, monkeypatch, nwGUI, projPath, mockRn
assert update[0][0] == C.iNew
assert update[0][1].name == "New"
assert update[0][1].color == QColor(120, 120, 120)
assert update[0][1].color.getRgb() == (179, 90, 179, 255)
assert update[0][1].shape == nwStatusShape.SQUARE
assert update[1][0] == C.iMajor
assert update[1][1].name == "Major"
assert update[1][1].color == QColor(220, 138, 221)
assert update[1][1].color.getRgb() == (179, 90, 179, 255)
assert update[1][1].shape == nwStatusShape.BLOCK_3
assert update[2][0] == C.iMain
assert update[2][1].name == "Main"
assert update[2][1].color == QColor(220, 138, 221)
assert update[2][1].color.getRgb() == (179, 90, 179, 255)
assert update[2][1].shape == nwStatusShape.BLOCK_4
assert update[3][0] is None
assert update[3][1].name == "Final"
assert update[3][1].color == QColor(20, 30, 40)
assert update[3][1].color.getRgb() == (20, 30, 40, 255)
assert update[3][1].shape == nwStatusShape.TRIANGLE
# Check Project
@@ -354,10 +354,10 @@ def testDlgProjSettings_StatusImportExport(qtbot, monkeypatch, nwGUI, projPath,
assert expFile.is_file() is True
assert expFile.read_text().split() == [
"STAR,#787878,New",
"TRIANGLE,#cdab8f,Note",
"CIRCLE_T,#8ff0a4,Draft",
"STAR,#f9f06b,Finished",
"STAR,#6c6c6c,New",
"TRIANGLE,#a62a2d,Note",
"CIRCLE_T,#a39c34,Draft",
"STAR,#296629,Finished",
]
# Import Error