-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Committing xsd changes for v12.35, v12.36 and v12.37. * Committing xsd changes for v12.37. * Committing test changes for v12.37. * Committing Batch test cases and CHANGELOG for V12.37 * Committing CHANGELOG for V12.37 --------- Co-authored-by: sghadage <[email protected]>
- Loading branch information
1 parent
534341e
commit a6a1d02
Showing
21 changed files
with
1,013 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
DIST_DIR_15=build/dist/java15 | ||
JAR_VERSION=12.34.1 | ||
JAR_VERSION=12.37.0 | ||
KIT_DIR=build/kit/java15 | ||
KIT_DEPENDENCIES_DIR=build/kit/java15/dependencies | ||
OPENSFTP_DIR=lib/opensftp-0.3.0 | ||
SCHEMA_VERSION=12.34 | ||
SCHEMA_VERSION=12.37 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
71 changes: 71 additions & 0 deletions
71
src/functionalTest/java/io/github/vantiv/sdk/TestBNPLAuthorizationRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
package io.github.vantiv.sdk; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import java.util.Calendar; | ||
|
||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
import io.github.vantiv.sdk.generate.BNPLAuthResponse; | ||
import io.github.vantiv.sdk.generate.BNPLAuthorizationRequest; | ||
import io.github.vantiv.sdk.generate.Contact; | ||
import io.github.vantiv.sdk.generate.CustomerInfo; | ||
import io.github.vantiv.sdk.generate.DetailTax; | ||
import io.github.vantiv.sdk.generate.EnhancedData; | ||
import io.github.vantiv.sdk.generate.FinicityAccountRequest; | ||
import io.github.vantiv.sdk.generate.FinicityAccountResponse; | ||
import io.github.vantiv.sdk.generate.Provider; | ||
|
||
public class TestBNPLAuthorizationRequest { | ||
|
||
private static CnpOnline cnp; | ||
|
||
@BeforeClass | ||
public static void beforeClass() throws Exception { | ||
cnp = new CnpOnline(); | ||
} | ||
|
||
|
||
@Test | ||
public void testSimpleBNPLAuthReqeust() throws Exception { | ||
BNPLAuthorizationRequest bnplAuthorizationRequest = new BNPLAuthorizationRequest(); | ||
bnplAuthorizationRequest.setId("url1"); | ||
bnplAuthorizationRequest.setReportGroup("XML10Mer1"); | ||
bnplAuthorizationRequest.setCustomerId("154646587"); | ||
bnplAuthorizationRequest.setAmount(106L); | ||
bnplAuthorizationRequest.setProvider(Provider.AFFIRM); | ||
bnplAuthorizationRequest.setOrderId("abc"); | ||
bnplAuthorizationRequest.setPostCheckoutRedirectUrl("www.abc"); | ||
CustomerInfo cust = new CustomerInfo(); | ||
cust.setAccountUsername("Woolfoo"); | ||
cust.setUserAccountNumber("123456ATY"); | ||
cust.setUserAccountEmail("[email protected]"); | ||
cust.setMembershipId("Member01"); | ||
cust.setMembershipPhone("9765431234"); | ||
cust.setMembershipEmail("[email protected]"); | ||
cust.setMembershipName("memName"); | ||
Calendar createDate = Calendar.getInstance(); | ||
createDate.set(1990, Calendar.MARCH, 16); | ||
cust.setAccountCreatedDate(createDate); | ||
cust.setUserAccountPhone("123456789"); | ||
bnplAuthorizationRequest.setCustomerInfo(cust); | ||
Contact contact = new Contact(); | ||
contact.setZip("95032"); | ||
bnplAuthorizationRequest.setBillToAddress(contact); | ||
bnplAuthorizationRequest.setShipToAddress(contact); | ||
EnhancedData enhanced = new EnhancedData(); | ||
DetailTax dt1 = new DetailTax(); | ||
dt1.setTaxAmount(100L); | ||
enhanced.getDetailTaxes().add(dt1); | ||
DetailTax dt2 = new DetailTax(); | ||
dt2.setTaxAmount(200L); | ||
enhanced.getDetailTaxes().add(dt2); | ||
bnplAuthorizationRequest.setEnhancedData(enhanced); | ||
BNPLAuthResponse response = cnp.bnplAuth(bnplAuthorizationRequest); | ||
assertEquals(response.getMessage(), "000",response.getResponse()); | ||
assertEquals("Approved", response.getMessage()); | ||
assertEquals("sandbox", response.getLocation()); | ||
} | ||
|
||
} |
38 changes: 38 additions & 0 deletions
38
src/functionalTest/java/io/github/vantiv/sdk/TestBNPLCancleRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package io.github.vantiv.sdk; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
import io.github.vantiv.sdk.generate.BNPLCancelRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCancelResponse; | ||
import io.github.vantiv.sdk.generate.BNPLCaptureRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCaptureResponse; | ||
|
||
public class TestBNPLCancleRequest { | ||
|
||
private static CnpOnline cnp; | ||
|
||
@BeforeClass | ||
public static void beforeClass() throws Exception { | ||
cnp = new CnpOnline(); | ||
} | ||
|
||
|
||
@Test | ||
public void testSimpleBNPLCancleReqeust() throws Exception { | ||
BNPLCancelRequest bnplCancelRequest = new BNPLCancelRequest(); | ||
bnplCancelRequest.setId("url1"); | ||
bnplCancelRequest.setReportGroup("XML10Mer1"); | ||
bnplCancelRequest.setCustomerId("154646587"); | ||
bnplCancelRequest.setAmount(106L); | ||
bnplCancelRequest.setOrderId("abc"); | ||
bnplCancelRequest.setCnpTxnId(106l); | ||
BNPLCancelResponse response = cnp.bnplCancle(bnplCancelRequest); | ||
assertEquals(response.getMessage(), "000",response.getResponse()); | ||
assertEquals("Approved", response.getMessage()); | ||
assertEquals("sandbox", response.getLocation()); | ||
} | ||
|
||
} |
45 changes: 45 additions & 0 deletions
45
src/functionalTest/java/io/github/vantiv/sdk/TestBNPLCaptureRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
package io.github.vantiv.sdk; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import java.util.Calendar; | ||
|
||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
import io.github.vantiv.sdk.generate.BNPLAuthResponse; | ||
import io.github.vantiv.sdk.generate.BNPLAuthorizationRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCaptureRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCaptureResponse; | ||
import io.github.vantiv.sdk.generate.Contact; | ||
import io.github.vantiv.sdk.generate.CustomerInfo; | ||
import io.github.vantiv.sdk.generate.DetailTax; | ||
import io.github.vantiv.sdk.generate.EnhancedData; | ||
import io.github.vantiv.sdk.generate.Provider; | ||
|
||
public class TestBNPLCaptureRequest { | ||
|
||
private static CnpOnline cnp; | ||
|
||
@BeforeClass | ||
public static void beforeClass() throws Exception { | ||
cnp = new CnpOnline(); | ||
} | ||
|
||
|
||
@Test | ||
public void testSimpleBNPLCaptureReqeust() throws Exception { | ||
BNPLCaptureRequest bnplCaptureRequest = new BNPLCaptureRequest(); | ||
bnplCaptureRequest.setId("url1"); | ||
bnplCaptureRequest.setReportGroup("XML10Mer1"); | ||
bnplCaptureRequest.setCustomerId("154646587"); | ||
bnplCaptureRequest.setAmount(106L); | ||
bnplCaptureRequest.setOrderId("abc"); | ||
bnplCaptureRequest.setCnpTxnId(106l); | ||
BNPLCaptureResponse response = cnp.bnplCapture(bnplCaptureRequest); | ||
assertEquals(response.getMessage(), "000",response.getResponse()); | ||
assertEquals("Approved", response.getMessage()); | ||
assertEquals("sandbox", response.getLocation()); | ||
} | ||
|
||
} |
37 changes: 37 additions & 0 deletions
37
src/functionalTest/java/io/github/vantiv/sdk/TestBNPLInquiryRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package io.github.vantiv.sdk; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
import io.github.vantiv.sdk.generate.BNPLCancelRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCancelResponse; | ||
import io.github.vantiv.sdk.generate.BNPLInquiryRequest; | ||
import io.github.vantiv.sdk.generate.BNPLInquiryResponse; | ||
|
||
public class TestBNPLInquiryRequest { | ||
|
||
private static CnpOnline cnp; | ||
|
||
@BeforeClass | ||
public static void beforeClass() throws Exception { | ||
cnp = new CnpOnline(); | ||
} | ||
|
||
|
||
@Test | ||
public void testSimpleBNPLInquiryReqeust() throws Exception { | ||
BNPLInquiryRequest Request = new BNPLInquiryRequest(); | ||
Request.setId("url1"); | ||
Request.setReportGroup("XML10Mer1"); | ||
Request.setCustomerId("154646587"); | ||
Request.setOrderId("abc"); | ||
Request.setCnpTxnId(106l); | ||
BNPLInquiryResponse response = cnp.bnplInquiry(Request); | ||
assertEquals(response.getMessage(), "000",response.getResponse()); | ||
assertEquals("Approved", response.getMessage()); | ||
assertEquals("sandbox", response.getLocation()); | ||
} | ||
|
||
} |
38 changes: 38 additions & 0 deletions
38
src/functionalTest/java/io/github/vantiv/sdk/TestBNPLRefundRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package io.github.vantiv.sdk; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
|
||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
|
||
import io.github.vantiv.sdk.generate.BNPLCaptureRequest; | ||
import io.github.vantiv.sdk.generate.BNPLCaptureResponse; | ||
import io.github.vantiv.sdk.generate.BNPLRefundRequest; | ||
import io.github.vantiv.sdk.generate.BNPLRefundResponse; | ||
|
||
public class TestBNPLRefundRequest { | ||
|
||
private static CnpOnline cnp; | ||
|
||
@BeforeClass | ||
public static void beforeClass() throws Exception { | ||
cnp = new CnpOnline(); | ||
} | ||
|
||
|
||
@Test | ||
public void testSimpleRefundReqeust() throws Exception { | ||
BNPLRefundRequest bnplRefundRequest = new BNPLRefundRequest(); | ||
bnplRefundRequest.setId("url1"); | ||
bnplRefundRequest.setReportGroup("XML10Mer1"); | ||
bnplRefundRequest.setCustomerId("154646587"); | ||
bnplRefundRequest.setAmount(106L); | ||
bnplRefundRequest.setOrderId("abc"); | ||
bnplRefundRequest.setCnpTxnId(106L); | ||
BNPLRefundResponse response = cnp.bnplRefund(bnplRefundRequest); | ||
assertEquals(response.getMessage(), "000",response.getResponse()); | ||
assertEquals("Approved", response.getMessage()); | ||
assertEquals("sandbox", response.getLocation()); | ||
} | ||
|
||
} |
Oops, something went wrong.