fix: 신강·신약을 득령 먼저 보고 판정 — 월령 오행이 일간을 도우면 +0.15, 45~55%는 중화 (未월 己土가 시주 하나로 신약이 되던 문제)

This commit is contained in:
minaChoi committed 2026-10-29 13:30:50 +09:00
1 parent b9dd0f203d
commit 263f01b4f1
9 files changed
+43 -11

No files matched your search

+1 -1
View File
@@ -36,7 +36,7 @@ async def test_reading_for_anyone_gives_me_today_and_cards(offline):
assert [p["stem"] + p["branch"] for p in r["me"]["pillars"]] == ["乙亥", "己卯", "甲辰"] and r["me"]["hour_known"] is False
assert r["me"]["scene"].endswith("기운") and r["today"]["title"] and 0 <= r["today"]["score"] <= 100
assert [(p.get("stem_ten_god"), p["branch_ten_god"]) for p in r["me"]["pillars"]] == [("겁재", "편인"), ("정재", "겁재"), (None, "편재")]
assert r["me"]["top_element"] == "木" and r["me"]["strong"] is True and r["me"]["elements"]["木"] == 58.3
assert r["me"]["top_element"] == "木" and r["me"]["strong"] is True and r["me"]["strength"] == "신강" and r["me"]["elements"]["木"] == 58.3
kinds = [x["kind"] for x in r["today"]["cards"]]
assert "when" in kinds and "do" in kinds and "wear" in kinds
# 근거 줄은 쉬운 말 + 괄호 용어, 숫자 없이
+9
View File
@@ -269,6 +269,15 @@ def test_summer_earth_chart_reads_hot_and_dry_not_rainy():
assert climate.strength.top == "土" and climate.strength.strong
def test_month_rooted_day_master_stays_strong_whatever_the_hour():
# 未월 己土는 득령(월령 土) — 시주가 물·쇠라도 신강, 득령 없는 같은 몫이면 낮게
for h in range(0, 24, 2):
s = chart_strength(make_chart(date(1959, 7, 16), time(h, 30)))
assert s.deuk_ryeong and s.label == "신강", (h, s)
winter = chart_strength(make_chart(date(1959, 12, 20))) # 子월 — 己土 득령 아님
assert not winter.deuk_ryeong
def test_month_dries_summer_earth_and_soaks_winter_earth():
assert seasoned("己", "未")[1] < 0 < seasoned("己", "子")[1]
assert seasoned("壬", "未")[0] > seasoned("壬", "子")[0]