Files
Pier_v1/tests/abut-visibility.test.ts
T
ypshimandClaude Haiku 5.5 b06bf368b6 feat(abut-rebar): ③ 교대 화면 틀과 확대기초 배근 카드
- ③에서 교대를 고르면 부재 · 교대 목록(받침블럭 → 벽체 → 흉벽·브라켓 → 확대기초 → 날개벽 → 접속슬래브)과 카드를 보여 줌.
  확대기초만 규칙이 있고 나머지는 '다음 단계'. 선택한 교대만 3D에 그림
- 확대기초 카드: 보기 탭 3개(교대축 직각 단면 · 교대축 단면 · 상면 평면)와 번호 풍선 강조, 범례,
  기본간격 · 배근 방향 ① / ② · 피복 · 여유 · B9 배수 입력, 자동 값(cycle 간격 · B10 위 여유 · l_s · 옆붙임),
  철근표(묶음별 실간격 수정 · 수정됨 · 되돌리기, 비고 펼치기), 근거 줄, RB-AF 알림
- 입력은 AbutRecord.rebar.footing에 바꾼 값만 저장 · 프로젝트 파일 검증. fck는 공통 설정의 기초부 값

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
2026-11-04 11:12:43 +09:00

33 lines
1.4 KiB
TypeScript

import { describe, expect, it } from 'vitest';
import { abutShown, piersShown } from '../src/core/abut/visibility';
describe('형상계획 ②: 선택한 객체만 3D에 그림', () => {
it('a selected abutment hides the piers in ②', () => {
expect(piersShown('plan', 'A1')).toBe(false);
expect(abutShown('plan', 'A1', 'A1')).toBe(true);
expect(abutShown('plan', 'A1', 'A2')).toBe(false);
});
it('a selected pier (no abutment selected) hides every abutment in ②', () => {
expect(piersShown('plan', null)).toBe(true);
expect(abutShown('plan', null, 'A1')).toBe(false);
expect(abutShown('plan', null, 'A2')).toBe(false);
});
it('① keeps the piers and every abutment as before', () => {
expect(piersShown('shape', 'A1')).toBe(true);
expect(piersShown('shape', null)).toBe(true);
expect(abutShown('shape', 'A1', 'A2')).toBe(true);
expect(abutShown('shape', null, 'A1')).toBe(true);
});
it('③ draws a selected abutment alone (2026-11-04); with no abutment selected ③ and ④ draw as before', () => {
expect(piersShown('rebar', 'A1')).toBe(false);
expect(abutShown('rebar', 'A1', 'A1')).toBe(true);
expect(abutShown('rebar', 'A1', 'A2')).toBe(false);
expect(piersShown('rebar', null)).toBe(true);
expect(abutShown('rebar', null, 'A1')).toBe(true);
expect(piersShown('quantity', 'A1')).toBe(true);
});
});