This commit is contained in:
gr
2026-10-30 13:43:29 +08:00
144 changed files with 16467 additions and 2457 deletions
+5 -4
View File
@@ -6,6 +6,7 @@ from PySide6.QtGui import QPalette
from PySide6.QtWidgets import QApplication, QFrame, QLabel, QPushButton
from doctor_workstation.core import PermissionSet
from doctor_workstation.ui.design_system import PALETTE
from doctor_workstation.ui.pages import reception as reception_module
from doctor_workstation.ui.pages.reception import ReceptionPage
from doctor_workstation.ui.theme import apply_theme
@@ -43,12 +44,12 @@ def page(application, monkeypatch):
def test_primary_action_and_reading_ink_use_separate_colors(page, application):
page.video_button.setEnabled(True)
settle(application)
assert page.video_button.palette().color(QPalette.ColorRole.Button).name() == "#1769e8"
assert page.video_button.palette().color(QPalette.ColorRole.ButtonText).name() == "#ffffff"
assert page.case_labels["present"].palette().color(QPalette.ColorRole.WindowText).name() == "#273244"
assert page.video_button.palette().color(QPalette.ColorRole.Button).name() == PALETTE["accent"].lower()
assert page.video_button.palette().color(QPalette.ColorRole.ButtonText).name() == PALETTE["surface"].lower()
assert page.case_labels["present"].palette().color(QPalette.ColorRole.WindowText).name() == PALETTE["text"].lower()
page.video_button.setEnabled(False)
settle(application)
assert page.video_button.palette().color(QPalette.ColorRole.ButtonText).name() == "#8e8f90"
assert page.video_button.palette().color(QPalette.ColorRole.ButtonText).name() == PALETTE["disabled"].lower()
def test_typography_preserves_regular_body_and_distinct_values(page):