aboutsummaryrefslogtreecommitdiff
path: root/tests/test_mainwindow_projects.py
diff options
context:
space:
mode:
authorBrianna Rainey2026-01-29 16:30:43 -0500
committerBrianna Rainey2026-01-29 16:30:43 -0500
commitb283aa418a1c0016a63a328fec6259dfe110cefe (patch)
treebfdc6f4700df9ffcf16f731a505217a153186aff /tests/test_mainwindow_projects.py
parent71a22c6a121d1294a05ef35020c525fa70cae2fd (diff)
fix `settings.ini` not located in correct path
Diffstat (limited to 'tests/test_mainwindow_projects.py')
-rw-r--r--tests/test_mainwindow_projects.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/test_mainwindow_projects.py b/tests/test_mainwindow_projects.py
index 8ad491a..6b49799 100644
--- a/tests/test_mainwindow_projects.py
+++ b/tests/test_mainwindow_projects.py
@@ -1,3 +1,5 @@
+from PyQt6 import QtCore
+import os
from pytest import fixture
from pytestqt import qtbot
from . import getTestDataPath, window
@@ -8,9 +10,17 @@ def test_mainwindow_clear(qtbot, window):
assert len(window.core.selectedComponents) == 0
+def test_mainwindow_presetDir_in_tests(qtbot, window):
+ # FIXME presetDir gets set to projectDir for some reason
+ assert (
+ os.path.basename(os.path.dirname(window.core.settings.value("presetDir")))
+ == "config"
+ )
+
+
def test_mainwindow_openProject(qtbot, window):
"""Open testproject.avp using MainWindow.openProject()"""
- window.openProject(getTestDataPath("projects/testproject.avp"), prompt=False)
+ window.openProject(getTestDataPath("config/projects/testproject.avp"), prompt=False)
assert len(window.core.selectedComponents) == 2