Spring Boot 3.5.14 결제 서비스 최소 구현 #2

Open
forge-bot wants to merge 4 commits from forge/BAIS-REVIEW-1783807356-attempt-2 into main
Showing only changes of commit ad48f30670 - Show all commits

View file

@ -0,0 +1,23 @@
package com.klaro.bais;
import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.*;
public class PaymentServiceTest {
private final PaymentService paymentService = new PaymentService();
@Test
public void testApproveWithPositiveAmount() {
assertTrue(paymentService.approve(100));
}
@Test
public void testApproveWithZeroAmount() {
assertFalse(paymentService.approve(0));
}
@Test
public void testApproveWithNegativeAmount() {
assertFalse(paymentService.approve(-100));
}
}