Files
Aislo/resources/tester/test_b07_sheet_key_place.py
T
eomsangdonandClaude Opus 5 f20213592c feat(b08): 구조물도 엔진·창구·화면 조각을 B07 에서 B08 로 이관
- 장 나눔·제원 입력 엔진과 기울기 판정 대상을 B08 로 옮김
- 창구를 /quantity/structure-sheets 로 옮기고 기초잡석 두께·지반 갈래를 함께 넘김
  (옛 B07 창구는 두께를 안 넘겨 원단위 탭과 값이 갈렸음)
- 구조물도 탭 조각 renderStructureSheets 신설 — 탭 등록은 브레인 몫이라 안 붙임
- B07 표준도 목록은 탭 배선 날까지 B08 엔진·창구를 불러 그대로 둠

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016VBGFXB9AbJBwXP19z75Qq
2026-09-13 14:48:13 +09:00

29 lines
1.1 KiB
Python

"""표준도 장 나눔 — **자리 칸(앞뒤 걸침)은 장을 가르지 않는다** (2026-09-13).
장 나눔 축은 「제원 조합」이다(PLAN 4-3). 구간 규약의 `before_m`·`after_m` 는 기준 측점에서
앞뒤로 얼마나 걸치나일 뿐이라, 제원이 같은 두 기가 이 칸 때문에 두 장이 되면 안 된다.
"""
from __future__ import annotations
import sys
from pathlib import Path
ROOT = Path(__file__).resolve().parents[2]
sys.path.insert(0, str(ROOT))
from B08_Quantity.B08_Quantity_Engine_StructureSheet import sheet_key # noqa: E402
def _stone(**options) -> dict:
return {"type_id": "masonry_wet", "height_m": 2.0, "options": {"back_len_cm": 45, **options}}
def test_앞뒤_걸침이_달라도_같은_장() -> None:
assert sheet_key(_stone(before_m=5, after_m=5)) == sheet_key(_stone(before_m=0, after_m=12))
assert sheet_key(_stone(outlet_revet_before_m=3)) == sheet_key(_stone())
def test_제원이_다르면_여전히_장이_갈린다() -> None:
assert sheet_key(_stone(before_m=5)) != sheet_key(_stone(before_m=5, back_len_cm=55))