From f496477ba0d7680b0963f0e6e0fbe38e360c7514 Mon Sep 17 00:00:00 2001 From: HeuJung Date: Wed, 15 Jul 2026 10:34:14 +0900 Subject: [PATCH] =?UTF-8?q?test(ecommerce):=20=EC=B2=B4=ED=81=AC=EC=95=84?= =?UTF-8?q?=EC=9B=83=20=EA=B2=B0=EC=A0=9C=EC=88=98=EB=8B=A8=20=ED=9A=8C?= =?UTF-8?q?=EA=B7=80=20=ED=85=8C=EC=8A=A4=ED=8A=B8=20mock=20=EC=9D=84=20se?= =?UTF-8?q?lectedCorePaymentMethod=20=EB=8F=84=EC=9E=85=EC=97=90=20?= =?UTF-8?q?=EB=A7=9E=EC=B6=B0=20=EC=A0=95=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 토스 주문서형 결제수단 도입으로 주문 body 표현식이 _computed.selectedPaymentMethod → selectedCorePaymentMethod (결제수단 id → core_payment_method 매핑) 로 바뀌었으나, ecommerce 회귀 테스트의 context 헬퍼가 selectedPaymentMethod 만 세팅한 채 새 키를 누락해 payment_method 가 undefined 로 평가되던 stale test 를 정정. 레이아웃 로직은 정상이며 템플릿 측 테스트가 동일 동작을 이미 커버한다. --- .../layouts/checkoutPaymentMethodRegression.test.tsx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/modules/_bundled/sirsoft-ecommerce/resources/js/__tests__/layouts/checkoutPaymentMethodRegression.test.tsx b/modules/_bundled/sirsoft-ecommerce/resources/js/__tests__/layouts/checkoutPaymentMethodRegression.test.tsx index c24f4ae1..1d9fa972 100644 --- a/modules/_bundled/sirsoft-ecommerce/resources/js/__tests__/layouts/checkoutPaymentMethodRegression.test.tsx +++ b/modules/_bundled/sirsoft-ecommerce/resources/js/__tests__/layouts/checkoutPaymentMethodRegression.test.tsx @@ -77,7 +77,15 @@ describe('체크아웃 결제수단 회귀 테스트', () => { const context = (paymentMethod: string, localPaymentMethod?: string) => ({ checkoutData: { data: { temp_order_id: 'T-1', calculation: { summary: { final_amount: 1000 } } } }, - _computed: { selectedPaymentMethod: paymentMethod, ordererDefaults: { name: '홍길동' } }, + // body 는 _computed.selectedCorePaymentMethod 를 싣는다(#454 S3 — 결제수단 id → + // core_payment_method 매핑). selectedPaymentMethod 는 선택된 결제수단 id, core 는 + // 그 id 가 가리키는 코어 결제수단(dbank/card/vbank …)이다. 이 회귀 테스트의 관심사인 + // "고른 결제수단이 그대로 실려 나가는가" 는 core 값으로 검증한다. + _computed: { + selectedPaymentMethod: paymentMethod, + selectedCorePaymentMethod: paymentMethod, + ordererDefaults: { name: '홍길동' }, + }, _local: { paymentMethod: localPaymentMethod, shipping: {},