Kairo-Jinkendo/backend/tests/test_backlog_vocabulary_unit.py
Lars 390161e224
All checks were successful
Deploy Development / deploy (push) Successful in 47s
Test Suite / pytest-backend (push) Successful in 4m15s
Test Suite / lint-backend (push) Successful in 2s
Test Suite / compose-smoke (push) Has been skipped
Test Suite / k6 /api/health Baseline (push) Successful in 19s
Test Suite / playwright-smoke (push) Successful in 20s
test: Assertions auf Kernel v0.4 und tech_debt-Vokabular anpassen
Behebt 6 CI-Failures nach Agent-Slots/Tech-Debt-Release.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-27 13:06:20 +02:00

51 lines
1.7 KiB
Python

"""Unit tests for backlog vocabulary resolution."""
from __future__ import annotations
from steering.backlog_vocabulary import resolve_backlog_vocabulary
def test_resolve_agile_from_steering_element():
vocab = resolve_backlog_vocabulary(
data_slices=["backlog", "actions", "work_cycles"],
method_key="continuous_product",
steering_elements=frozenset(
{"work_cycle_scope", "backlog_epic_hierarchy", "next_action_primary"}
),
)
assert vocab["profile_key"] == "agile_intake"
assert vocab["capabilities"]["epic_hierarchy"] is True
assert vocab["capabilities"]["sprint_commit"] is True
assert "epic" in vocab["kinds"]
def test_resolve_continuous_without_epic_element():
vocab = resolve_backlog_vocabulary(
data_slices=["backlog", "actions"],
method_key="continuous_product",
steering_elements=frozenset({"next_action_primary"}),
)
assert vocab["profile_key"] == "continuous_intake"
assert vocab["labels"]["story"] == "Idee"
assert vocab["capabilities"]["epic_hierarchy"] is False
def test_resolve_standard_for_generic_backlog():
vocab = resolve_backlog_vocabulary(
data_slices=["backlog", "actions"],
method_key="sequential_dependency",
steering_elements=frozenset({"critical_path", "next_action_primary"}),
)
assert vocab["profile_key"] == "standard_intake"
assert vocab["labels"]["story"] == "Story"
assert "tech_debt" in vocab["kinds"]
def test_resolve_empty_without_backlog_slice():
vocab = resolve_backlog_vocabulary(
data_slices=["actions", "roadmap"],
method_key="maturity_progression",
steering_elements=frozenset({"next_action_primary"}),
)
assert vocab["kinds"] == []