Files
Pier_v1/tests/footing-inputs.test.ts
T
CopilotandCopilot 06e1b97a62
ITAM Code Check / build-and-config-check (push) Failing after 37s
ITAM Docker Build Check / docker-build-check (push) Failing after 1m0s
교각 프로그램 초기 버전
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-11-02 15:55:01 +09:00

29 lines
1.3 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import { describe, expect, it } from 'vitest';
import { buildPier, footingDims } from '../src/core/geometry';
import { loadP1 } from './helpers';
describe('확대기초·말뚝 입력 (입력만, 승인 2026-10-23)', () => {
it('without the new inputs the footing dims are the 1단계 constants (P1 unchanged)', () => {
const d = footingDims(loadP1());
expect(d.L).toBeCloseTo(10.4, 9);
expect(d.W).toBeCloseTo(8.15, 9);
expect(d.H).toBeCloseTo(2.0, 9);
expect(d.blM).toBeCloseTo(0.2, 9);
expect(d.blT).toBeCloseTo(0.1, 9);
expect(d.pileD).toBeCloseTo(0.6096, 9);
});
it('the footing width, height and blinding follow the inputs in the model', () => {
const m = buildPier({ ...loadP1(), footingWidthMm: 9000, footingHeightMm: 2200, blindingMarginMm: 150, blindingThicknessMm: 120 });
expect(m.footings[0].width).toBeCloseTo(9.0, 9);
expect(m.blindings[0].width).toBeCloseTo(9.0 + 0.3, 9);
expect(m.blindings[0].thickness).toBeCloseTo(0.12, 9);
expect(m.footings[0].top - m.footings[0].bottom).toBeCloseTo(2.2, 9);
});
it('a steel pile of 609.6 × 16 gives the pile diameter 0.6096 m (the wall is in the list, not the diameter)', () => {
const m = buildPier({ ...loadP1(), pileOuterMm: 609.6, pileThicknessMm: 16 });
expect(m.piles[0].diameter).toBeCloseTo(0.6096, 9);
});
});