From b991899a5d77c8473d41e20ed1f9000a9670620a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=98=BF=E7=99=BD=E5=8F=94?= <11794527+absfan@user.noreply.gitee.com> Date: Sat, 31 Oct 2026 10:09:46 +0800 Subject: [PATCH] test(ui): keep default collection aligned with workspace layout --- pyproject.toml | 2 +- tests/v1_1/test_project_task_ui.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 5265ef7..c946ca2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -22,7 +22,7 @@ dev = ["pytest>=8,<9", "pytest-cov>=5,<7", "coverage>=7,<8", "build>=1.2,<2", "p where = ["src"] [tool.pytest.ini_options] -testpaths = ["tests/v1_1"] +testpaths = ["tests/v1_1", "tests/ui"] pythonpath = ["src"] addopts = "-ra" cache_dir = "build/pytest-cache" diff --git a/tests/v1_1/test_project_task_ui.py b/tests/v1_1/test_project_task_ui.py index 623b8c7..e37005f 100644 --- a/tests/v1_1/test_project_task_ui.py +++ b/tests/v1_1/test_project_task_ui.py @@ -164,7 +164,7 @@ def test_blank_bom_can_be_downloaded_without_task_or_inventory(qtbot, tmp_path, store.close() -def test_batch_rules_and_target_plan_are_above_project_summary(qtbot, tmp_path): +def test_project_summary_is_above_batch_rules_and_target_plan(qtbot, tmp_path): from dx_productivity.trial_task_center.service import TaskCenterService from dx_productivity.trial_task_center.store import TaskStore from dx_productivity.trial_task_center.logging_setup import configure_logging @@ -180,7 +180,7 @@ def test_batch_rules_and_target_plan_are_above_project_summary(qtbot, tmp_path): qtbot.waitExposed(window) assert window.mapping_tabs.objectName() == 'batchPlanTabs' from PySide6.QtCore import QPoint - assert window.mapping_tabs.mapTo(window, QPoint()).y() < window.project_summary.mapTo(window, QPoint()).y() + assert window.project_summary.mapTo(window, QPoint()).y() < window.mapping_tabs.mapTo(window, QPoint()).y() assert window.mapping_tabs.tabText(0) == '本批料号规则' assert window.mapping_tabs.tabText(1) == '本批位号计划' window.close(); store.close()