diff --git a/.forge/BAIS-CTX-1783821073-attempt-4.md b/.forge/BAIS-CTX-1783821073-attempt-1.md similarity index 63% rename from .forge/BAIS-CTX-1783821073-attempt-4.md rename to .forge/BAIS-CTX-1783821073-attempt-1.md index 27c880c..fa332cd 100644 --- a/.forge/BAIS-CTX-1783821073-attempt-4.md +++ b/.forge/BAIS-CTX-1783821073-attempt-1.md @@ -1,3 +1,3 @@ -# BAIS-CTX-1783821073-attempt-4 +# BAIS-CTX-1783821073-attempt-1 -Forge 이슈 작업 브랜치 `forge/BAIS-CTX-1783821073-attempt-4`. +Forge 이슈 작업 브랜치 `forge/BAIS-CTX-1783821073-attempt-1`. diff --git a/pom.xml b/pom.xml index d025c7b..3a06184 100644 --- a/pom.xml +++ b/pom.xml @@ -1,22 +1,15 @@ - - + 4.0.0 - org.springframework.boot spring-boot-starter-parent 3.5.14 - com.klaro.bais bais-platform 1.0-SNAPSHOT pom - services/payments - - \ No newline at end of file + diff --git a/services/payments/pom.xml b/services/payments/pom.xml index f4d20af..0bddfb9 100644 --- a/services/payments/pom.xml +++ b/services/payments/pom.xml @@ -1,16 +1,11 @@ - - + 4.0.0 - com.klaro.bais bais-platform 1.0-SNAPSHOT ../../pom.xml - payments @@ -18,12 +13,5 @@ commons-lang3 3.18.0 - - org.springframework.boot - spring-boot-starter-test - 3.5.14 - test - - - \ No newline at end of file + diff --git a/services/payments/src/main/java/com/klaro/bais/payments/PaymentReferenceService.java b/services/payments/src/main/java/com/klaro/bais/payments/PaymentReferenceService.java index a349b69..159a78d 100644 --- a/services/payments/src/main/java/com/klaro/bais/payments/PaymentReferenceService.java +++ b/services/payments/src/main/java/com/klaro/bais/payments/PaymentReferenceService.java @@ -6,4 +6,4 @@ public class PaymentReferenceService { public String normalize(String input) { return StringUtils.trimToEmpty(input); } -} \ No newline at end of file +} diff --git a/services/payments/src/test/java/com/klaro/bais/payments/PaymentReferenceServiceTest.java b/services/payments/src/test/java/com/klaro/bais/payments/PaymentReferenceServiceTest.java index b363d79..ee30f15 100644 --- a/services/payments/src/test/java/com/klaro/bais/payments/PaymentReferenceServiceTest.java +++ b/services/payments/src/test/java/com/klaro/bais/payments/PaymentReferenceServiceTest.java @@ -1,24 +1,28 @@ package com.klaro.bais.payments; import org.junit.jupiter.api.Test; -import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.*; class PaymentReferenceServiceTest { - - private final PaymentReferenceService service = new PaymentReferenceService(); + private final PaymentReferenceService paymentReferenceService = new PaymentReferenceService(); @Test - void testNormalizeNull() { - assertEquals("", service.normalize(null)); + void testNormalize_NullInput() { + assertEquals("", paymentReferenceService.normalize(null)); } @Test - void testNormalizeEmpty() { - assertEquals("", service.normalize(" ")); + void testNormalize_EmptyInput() { + assertEquals("", paymentReferenceService.normalize("")); } @Test - void testNormalizeNormalString() { - assertEquals("test", service.normalize(" test ")); + void testNormalize_WhitespaceInput() { + assertEquals("", paymentReferenceService.normalize(" ")); } -} \ No newline at end of file + + @Test + void testNormalize_RegularInput() { + assertEquals("Hello", paymentReferenceService.normalize(" Hello ")); + } +}