feat(rebar): 철근표 간격·실간격을 입력과 연동, 근거는 기본값/입력
- C1–C8: 간격 2 × 주철근 기본간격, 실간격 기본간격 - C9·C11 · C10 · C12·C13 · C14: 전단·측면·C14 간격 입력 - S1·S2: 블록 철근 간격 입력 - 근거: 관련 입력이 모두 기본값이면 '기본값', 하나라도 바뀌면 '입력' - 입력이 없는 행(C15·C16, P3~P5, 커플러)은 기존 고정값 유지 Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
1e6b8db7e9
commit
3cfbdf62f6
2 files changed
+54
-3
No files matched your search
@@ -34,6 +34,22 @@ describe('C1–C8 상·하면 주철근 (코핑철근.md §5, plan C3)', () => {
|
||||
expect(w120.count).toBe(25);
|
||||
});
|
||||
|
||||
it('철근표 간격: P1 기본값은 250 / 125 · 기본값 근거, 기본간격 140이면 280 / 140 · 입력 근거', () => {
|
||||
const base = rebarSummary(buildPier(loadP1())).rows;
|
||||
const c1 = base.find((r) => r.name === 'C1')!;
|
||||
expect([c1.spacing, c1.actual, c1.basis]).toEqual(['250', '125', 'default']);
|
||||
const c12 = base.find((r) => r.name === 'C12')!;
|
||||
expect(c12.basis).toBe('default');
|
||||
|
||||
const m = buildPier({ ...loadP1(), copingRebar: { mainSpacing: 140 }, blockRebar: { spacingS1: 130 } });
|
||||
const rows = rebarSummary(m).rows;
|
||||
const c8 = rows.find((r) => r.name === 'C8')!;
|
||||
expect([c8.spacing, c8.actual, c8.basis]).toEqual(['280', '140', 'input']);
|
||||
expect(rows.find((r) => r.name === 'C12')!.basis).toBe('default');
|
||||
const s1 = rows.find((r) => r.name === 'S1')!;
|
||||
expect([s1.spacing, s1.actual, s1.basis]).toEqual(['130', '130', 'input']);
|
||||
});
|
||||
|
||||
it('CP04: the default P1 has an even count (no warning); 기본간격 120 gives an odd count and a CP04 warning', () => {
|
||||
const base = rebarSummary(buildPier(loadP1())).warnings.filter((w) => w.code === 'CP04');
|
||||
expect(base).toEqual([]);
|
||||
|
||||
Reference in new issue
Block a user