diff --git a/resources/tester/helper_54_10_soil_tiers.cjs b/resources/tester/helper_54_10_soil_tiers.cjs index a2d7ae6db..823b29543 100644 --- a/resources/tester/helper_54_10_soil_tiers.cjs +++ b/resources/tester/helper_54_10_soil_tiers.cjs @@ -138,13 +138,8 @@ const ctx = { updates.push({ role, ...patch }); const now = adjusts[role] ?? { x: 0, d: null, h: null, m: null }; const m = patch.m === undefined ? now.m : patch.m; - // 기하 되받기(syncApplied) 흉내 — 형태 한계로 자름(돌쌓기(메) 2.0) - const h = - patch.h == null - ? patch.h === undefined - ? now.h - : null - : Math.min(patch.h, m === "돌쌓기(메)" ? 2.0 : 5.0); + // 기하 되받기(syncApplied) 흉내 — 형태별 높이 한도 없음(54-42 · 입력 높이 그대로) + const h = patch.h === undefined ? now.h : patch.h; adjusts[role] = { ...now, h, m }; }, }, @@ -173,9 +168,18 @@ applyPipeOptionsToCache(ctx, 100, { soil_add_1_form: "콘크리트", soil_add_1_height: 1.8, soil_add_2_form: "돌쌓기(메)", - soil_add_2_height: 2.0, + soil_add_2_height: 2.5, }); out.same = { updates: updates.splice(0), tiers: tiers.splice(0) }; +// 그림이 안 서는 높이(0 이하)만 하한 0.1 에서 멈춰 폼에 되돌림 · 토스트 없음(54-51) +applyPipeOptionsToCache(ctx, 100, { + soil_add_1_form: "콘크리트", + soil_add_1_height: 0, + soil_add_2_form: "돌쌓기(메)", + soil_add_2_height: 2.5, +}); +out.floor = { updates: updates.splice(0), overrides: overrides.splice(0) }; +out.toasts.push(...toasts.splice(0)); // 비운 칸 = 자동(높이 · 형태) · 구간값은 그대로 applyPipeOptionsToCache(ctx, 100, {}); out.cleared = { updates: updates.splice(0), tiers: tiers.splice(0) }; diff --git a/resources/tester/test_54_10_soil_tiers.py b/resources/tester/test_54_10_soil_tiers.py index b5a3b4d51..bd116dcda 100644 --- a/resources/tester/test_54_10_soil_tiers.py +++ b/resources/tester/test_54_10_soil_tiers.py @@ -39,7 +39,7 @@ def extras(updates: list[dict]) -> list[dict]: def test_컨테이너_형태_높이가_그_단_조정값으로(out) -> None: assert extras(out["filled"]["updates"]) == [ {"role": "extra0", "h": 1.8, "m": "콘크리트"}, - {"role": "extra1", "h": 2.0, "m": "돌쌓기(메)"}, + {"role": "extra1", "h": 2.5, "m": "돌쌓기(메)"}, # 형태별 높이 한도 없음(54-42) ] @@ -48,9 +48,12 @@ def test_지형이_못_세운_단은_그림에_안_감(out) -> None: assert "extra2" not in roles -def test_높이_한도는_형태_규칙_그대로_폼에_되돌림(out) -> None: - assert out["filled"]["overrides"] == [{"soil_add_2_height": 2}] - assert out["toasts"] == ["흙막이 2 높이는 형태 한계로 2.0m까지만 적용됩니다."] +def test_높이는_입력_그대로_0_이하만_하한으로_폼에_되돌림(out) -> None: + """54-42 형태별 한도 삭제 · 54-51 높이 제약 풀기 — 하한은 그림이 서는 0.1 하나 · 토스트 없음.""" + assert out["filled"]["overrides"] == [] + assert extras(out["floor"]["updates"]) == [{"role": "extra0", "h": 0.1, "m": "콘크리트"}] + assert out["floor"]["overrides"] == [{"soil_add_1_height": 0.1}] + assert out["toasts"] == [] def test_길이_전_후는_단별_구간값(out) -> None: