test:米阳受托协议支付相关临时test
parent
b09fac340b
commit
446bbb259c
|
|
@ -61,7 +61,7 @@ public class EntPayService {
|
|||
/**
|
||||
* 300311-协议支付
|
||||
*/
|
||||
public EntPayAgrtPayResponse commonAgrtPay(EntPayAgrtPayRequest request) {
|
||||
public EntPayAgrtPayResponse agrtPay(EntPayAgrtPayRequest request) {
|
||||
String url = "/entpay/agrt-pay";
|
||||
HttpResponse<EntPayAgrtPayResponse> httpResponse = apiClient.post(url, HttpHeaders.apiVersionV2(),
|
||||
request.toJsonRequest(), EntPayAgrtPayResponse.class);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,76 @@
|
|||
package com.czcb.scfs.api.test.service;
|
||||
|
||||
|
||||
import com.czcb.scfs.api.service.v2.customization.miyang.entpay.EntPayService;
|
||||
import com.czcb.scfs.api.service.v2.customization.miyang.entpay.model.*;
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* 米阳受托支付功能
|
||||
*
|
||||
* @author H.T
|
||||
* @since 2024-07-29
|
||||
*/
|
||||
@SpringBootTest
|
||||
class EntPayServiceTest {
|
||||
|
||||
private static final Logger log = LoggerFactory.getLogger(EntPayServiceTest.class);
|
||||
@Resource
|
||||
private EntPayService service;
|
||||
|
||||
@Test
|
||||
void agrtCreateTest() {
|
||||
try {
|
||||
EntPayAgrtCreateResponse response = service.agrtCreate(new EntPayAgrtCreateRequest());
|
||||
Assertions.assertEquals("000000", response.getRecode());
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void agrtDelTest() {
|
||||
try {
|
||||
EntPayAgrtDelResponse response = service.agrtDel(new EntPayAgrtDelRequest());
|
||||
Assertions.assertEquals("000000", response.getRecode());
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void agrtQueryListTest() {
|
||||
try {
|
||||
EntPayAgrtQueryListResponse response = service.agrtQueryList(new EntPayAgrtQueryListRequest());
|
||||
Assertions.assertEquals("000000", response.getRecode());
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void commonAgrtPayTest() {
|
||||
try {
|
||||
CommonAgrtPayResponse response = service.commonAgrtPay(new CommonAgrtPayRequest());
|
||||
Assertions.assertEquals("000000", response.getRecode());
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
void agrtPayTest() {
|
||||
try {
|
||||
EntPayAgrtPayResponse response = service.agrtPay(new EntPayAgrtPayRequest());
|
||||
Assertions.assertEquals("000000", response.getRecode());
|
||||
} catch (Exception e) {
|
||||
log.info(e.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue