generated from pricelees/issue-pr-template
refactor: payment 내 RestClient 관련 클래스(error, deserializer) 패키지 이동
This commit is contained in:
parent
571f6b2e11
commit
635f015b3c
@ -1,4 +1,4 @@
|
||||
package roomescape.payment.web.support
|
||||
package roomescape.payment.infrastructure.client
|
||||
|
||||
import com.fasterxml.jackson.core.JsonParser
|
||||
import com.fasterxml.jackson.core.TreeNode
|
||||
@ -28,4 +28,4 @@ class PaymentCancelResponseDeserializer(
|
||||
OffsetDateTime.parse(cancels.get("canceledAt").asText())
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,7 @@
|
||||
package roomescape.payment.infrastructure.client
|
||||
|
||||
@JvmRecord
|
||||
data class TossPaymentErrorResponse(
|
||||
val code: String,
|
||||
val message: String
|
||||
)
|
||||
@ -2,7 +2,7 @@ package roomescape.payment.web
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize
|
||||
import roomescape.payment.web.support.PaymentCancelResponseDeserializer
|
||||
import roomescape.payment.infrastructure.client.PaymentCancelResponseDeserializer
|
||||
import roomescape.reservation.dto.response.ReservationResponse
|
||||
import java.time.OffsetDateTime
|
||||
|
||||
|
||||
@ -7,6 +7,7 @@ import io.kotest.assertions.assertSoftly
|
||||
import io.kotest.core.spec.style.StringSpec
|
||||
import io.kotest.matchers.shouldBe
|
||||
import roomescape.payment.SampleTossPaymentConst
|
||||
import roomescape.payment.infrastructure.client.PaymentCancelResponseDeserializer
|
||||
import roomescape.payment.web.PaymentCancel
|
||||
|
||||
class PaymentCancelResponseDeserializerTest : StringSpec({
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user