Files
kanbante/tests/test_theme_agent.py
bruno c35aafd2e2
CI / test (push) Failing after 0s
CI / test (pull_request) Successful in 4m32s
Page Projets : copie URL dans le menu ⋯ + refonte thème barre Fusion/Spark (#44, #45)
2026-10-28 22:47:12 -04:00

29 lines
1.0 KiB
Python

"""Thème du site (#49) : Kanbante doit ressembler à la console
agent / barre Fusion (draco-barre, Console v7.2), pas au bleu/mauve
historique. Le test fige les jetons et interdit le retour des
littéraux violet/bleu de thème dans style.css.
"""
def test_theme_agent_tokens(client, fake_gitea):
css = client.get("/static/css/style.css").text
assert "--bg: #101211;" in css
assert "--surface: #1a1c1a;" in css
assert "--surface-2: #242624;" in css
assert "--surface-3: #20221f;" in css
assert "--border: #2e302c;" in css
assert "--text: #eceee9;" in css
assert "--accent: #c2437e;" in css
assert "--accent-2: #e078a8;" in css
def test_no_blue_purple_theme_literals(client, fake_gitea):
css = client.get("/static/css/style.css").text
for banned in (
"#7c5cfc", "#5b8af7", "#58a6ff", "#a78bfa", "#7dd3fc",
"#c4b5fd", "#a5c4fd", "#0b0e14", "#141822", "#1b202e",
"#232939", "124, 92, 252", "124,92,252",
"91, 138, 247", "91,138,247",
):
assert banned not in css, banned