globalpayments-api 3.10.2 → 3.10.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/CHANGELOG.md +191 -184
  2. package/LICENSE.md +257 -257
  3. package/README.md +141 -141
  4. package/lib/src/Gateways/PorticoConnector.js +3 -2
  5. package/lib/src/Gateways/PorticoConnector.js.map +1 -1
  6. package/lib/test/Integration/Gateways/GpApiConnector/3DS2.test.js +15 -15
  7. package/lib/test/Integration/Gateways/GpApiConnector/3DSecure.test.js +5 -5
  8. package/lib/test/Integration/Gateways/GpEcomConnector/Credit.test.js +4 -4
  9. package/lib/test/Integration/Gateways/PorticoConnector/Credit.test.js +26 -0
  10. package/lib/test/Integration/Gateways/PorticoConnector/Credit.test.js.map +1 -1
  11. package/lib/test/Integration/Gateways/PorticoConnector/Ecommerce.test.js +8 -8
  12. package/package.json +62 -62
  13. package/appsec.properties +0 -8
  14. package/lib/src/Gateways/RealexConnector.d.ts +0 -30
  15. package/lib/src/Gateways/RealexConnector.js +0 -523
  16. package/lib/src/ServicesConfig.d.ts +0 -27
  17. package/lib/src/ServicesConfig.js +0 -50
  18. package/lib/test/Integration/Gateways/PorticoConnector/AchTest.d.ts +0 -1
  19. package/lib/test/Integration/Gateways/PorticoConnector/AchTest.js +0 -112
  20. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.d.ts +0 -1
  21. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/CheckTest.js +0 -483
  22. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.d.ts +0 -1
  23. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceCheckTest.js +0 -83
  24. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.d.ts +0 -1
  25. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/EcommerceTest.js +0 -1720
  26. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.d.ts +0 -1
  27. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoCheckTest.js +0 -83
  28. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.d.ts +0 -1
  29. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/MotoTest.js +0 -1757
  30. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.d.ts +0 -1
  31. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RecurringTest.js +0 -682
  32. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.d.ts +0 -1
  33. package/lib/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.js +0 -2218
  34. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.d.ts +0 -1
  35. package/lib/test/Integration/Gateways/PorticoConnector/CreditTest.js +0 -707
  36. package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.d.ts +0 -1
  37. package/lib/test/Integration/Gateways/PorticoConnector/DebitTest.js +0 -151
  38. package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.d.ts +0 -1
  39. package/lib/test/Integration/Gateways/PorticoConnector/EbtTest.js +0 -171
  40. package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.d.ts +0 -1
  41. package/lib/test/Integration/Gateways/PorticoConnector/EcommerceTest.js +0 -192
  42. package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.d.ts +0 -1
  43. package/lib/test/Integration/Gateways/PorticoConnector/GiftTest.js +0 -377
  44. package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.d.ts +0 -1
  45. package/lib/test/Integration/Gateways/PorticoConnector/RecurringTest.js +0 -196
  46. package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.d.ts +0 -1
  47. package/lib/test/Integration/Gateways/PorticoConnector/ReportingTest.js +0 -53
  48. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.d.ts +0 -1
  49. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/GetInformationCertificationTests.js +0 -100
  50. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.d.ts +0 -1
  51. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayAccountCertificationTests.js +0 -352
  52. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.d.ts +0 -1
  53. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayFundCertificationTests.js +0 -123
  54. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.d.ts +0 -1
  55. package/lib/test/Integration/Gateways/ProPayConnector/Certifications/ProPayInNetworkTransactionCertificationTests.js +0 -142
  56. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.d.ts +0 -1
  57. package/lib/test/Integration/Gateways/ProPayConnector/GetInformationTests.js +0 -100
  58. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.d.ts +0 -1
  59. package/lib/test/Integration/Gateways/ProPayConnector/ProPayAccountTests.js +0 -535
  60. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.d.ts +0 -1
  61. package/lib/test/Integration/Gateways/ProPayConnector/ProPayFundsTests.js +0 -124
  62. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.d.ts +0 -1
  63. package/lib/test/Integration/Gateways/ProPayConnector/ProPayInNetworkTransactionTests.js +0 -144
  64. package/lib/test/Integration/Gateways/RealexConnector/Certification/AuthTest.d.ts +0 -1
  65. package/lib/test/Integration/Gateways/RealexConnector/Certification/AuthTest.js +0 -4373
  66. package/lib/test/Integration/Gateways/RealexConnector/Certification/AvsTest.d.ts +0 -1
  67. package/lib/test/Integration/Gateways/RealexConnector/Certification/AvsTest.js +0 -758
  68. package/lib/test/Integration/Gateways/RealexConnector/Certification/CreditTest.d.ts +0 -1
  69. package/lib/test/Integration/Gateways/RealexConnector/Certification/CreditTest.js +0 -2399
  70. package/lib/test/Integration/Gateways/RealexConnector/Certification/HoldTest.d.ts +0 -1
  71. package/lib/test/Integration/Gateways/RealexConnector/Certification/HoldTest.js +0 -1656
  72. package/lib/test/Integration/Gateways/RealexConnector/Certification/ManualTest.d.ts +0 -1
  73. package/lib/test/Integration/Gateways/RealexConnector/Certification/ManualTest.js +0 -5650
  74. package/lib/test/Integration/Gateways/RealexConnector/Certification/OtbTest.d.ts +0 -1
  75. package/lib/test/Integration/Gateways/RealexConnector/Certification/OtbTest.js +0 -1985
  76. package/lib/test/Integration/Gateways/RealexConnector/Certification/RebateTest.d.ts +0 -1
  77. package/lib/test/Integration/Gateways/RealexConnector/Certification/RebateTest.js +0 -2369
  78. package/lib/test/Integration/Gateways/RealexConnector/Certification/ReleaseTest.d.ts +0 -1
  79. package/lib/test/Integration/Gateways/RealexConnector/Certification/ReleaseTest.js +0 -1703
  80. package/lib/test/Integration/Gateways/RealexConnector/Certification/SettleTest.d.ts +0 -1
  81. package/lib/test/Integration/Gateways/RealexConnector/Certification/SettleTest.js +0 -2053
  82. package/lib/test/Integration/Gateways/RealexConnector/Certification/ValidationTest.d.ts +0 -1
  83. package/lib/test/Integration/Gateways/RealexConnector/Certification/ValidationTest.js +0 -2469
  84. package/lib/test/Integration/Gateways/RealexConnector/Certification/VerifyEnrolledTest.d.ts +0 -1
  85. package/lib/test/Integration/Gateways/RealexConnector/Certification/VerifyEnrolledTest.js +0 -3116
  86. package/lib/test/Integration/Gateways/RealexConnector/Certification/VoidTest.d.ts +0 -1
  87. package/lib/test/Integration/Gateways/RealexConnector/Certification/VoidTest.js +0 -2031
  88. package/lib/test/Integration/Gateways/RealexConnector/CreditTest.d.ts +0 -1
  89. package/lib/test/Integration/Gateways/RealexConnector/CreditTest.js +0 -322
  90. package/lib/test/Integration/Gateways/RealexConnector/HppTest.d.ts +0 -1
  91. package/lib/test/Integration/Gateways/RealexConnector/HppTest.js +0 -98
  92. package/lib/test/Integration/Gateways/RealexConnector/RecurringTest.d.ts +0 -1
  93. package/lib/test/Integration/Gateways/RealexConnector/RecurringTest.js +0 -263
  94. package/lib/test/Integration/Services/CheckServiceTest.d.ts +0 -1
  95. package/lib/test/Integration/Services/CheckServiceTest.js +0 -98
  96. package/lib/test/Integration/Services/CreditServiceTest.d.ts +0 -1
  97. package/lib/test/Integration/Services/CreditServiceTest.js +0 -313
  98. package/lib/test/Integration/Services/DebitServiceTest.d.ts +0 -1
  99. package/lib/test/Integration/Services/DebitServiceTest.js +0 -154
  100. package/lib/test/Integration/Services/EBTServiceTest.d.ts +0 -1
  101. package/lib/test/Integration/Services/EBTServiceTest.js +0 -135
  102. package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.d.ts +0 -1
  103. package/lib/test/Unit/Builders/AuthorizationBuilder/ValidationTest.js +0 -161
  104. package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.d.ts +0 -1
  105. package/lib/test/Unit/Builders/ReportBuilder/ValidationTest.js +0 -139
  106. package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.d.ts +0 -1
  107. package/lib/test/Unit/Gateways/PorticoConnector/InputValidationTest.js +0 -202
  108. package/lib/test/Unit/Gateways/RealexConnector/CreditTest.d.ts +0 -1
  109. package/lib/test/Unit/Gateways/RealexConnector/CreditTest.js +0 -29
@@ -1,2053 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __generator = (this && this.__generator) || function (thisArg, body) {
12
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
13
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
14
- function verb(n) { return function (v) { return step([n, v]); }; }
15
- function step(op) {
16
- if (f) throw new TypeError("Generator is already executing.");
17
- while (_) try {
18
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
- if (y = 0, t) op = [op[0] & 2, t.value];
20
- switch (op[0]) {
21
- case 0: case 1: t = op; break;
22
- case 4: _.label++; return { value: op[1], done: false };
23
- case 5: _.label++; y = op[1]; op = [0]; continue;
24
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
25
- default:
26
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
27
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
28
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
29
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
30
- if (t[2]) _.ops.pop();
31
- _.trys.pop(); continue;
32
- }
33
- op = body.call(thisArg, _);
34
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
35
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
36
- }
37
- };
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- var ava_1 = require("ava");
40
- var src_1 = require("../../../../../src/");
41
- var throttle = function () { return new Promise(function (resolve) { return setTimeout(resolve, 1500); }); };
42
- ava_1.default.beforeEach(function () { return __awaiter(void 0, void 0, void 0, function () {
43
- return __generator(this, function (_a) {
44
- switch (_a.label) {
45
- case 0: return [4 /*yield*/, throttle()];
46
- case 1:
47
- _a.sent();
48
- return [2 /*return*/];
49
- }
50
- });
51
- }); });
52
- // test("JAVA_Settle_Sample", async (t) => {
53
- // t.plan(4);
54
- // const config = new ServicesConfig();
55
- // config.merchantId = "heartlandgpsandbox";
56
- // config.accountId = "api";
57
- // config.sharedSecret = "secret";
58
- // config.refundPassword = "refund";
59
- // config.rebatePassword = "rebate";
60
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
61
- // config.timeout = 5000;
62
- // config.channel = "ECOM";
63
- // ServicesContainer.configure(config);
64
- // // create card
65
- // const card = new CreditCardData();
66
- // card.number = "4263970000005262";
67
- // card.expMonth = "12";
68
- // card.expYear = "2020";
69
- // card.cvn = "123";
70
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
71
- // card.cardHolderName = "James Mason";
72
- // // build transaction
73
- // const saleResponse = await card.authorize(1)
74
- // .withCurrency("EUR")
75
- // .execute();
76
- // t.truthy(saleResponse);
77
- // t.is("00", saleResponse.responseCode);
78
- // await throttle();
79
- // // request
80
- // const response = await saleResponse.capture(1)
81
- // .withCurrency("EUR")
82
- // .withDescription("JAVA-Settle")
83
- // .execute();
84
- // t.truthy(response);
85
- // t.is("00", response.responseCode);
86
- // });
87
- // test("JAVA_Settle_006a", async (t) => {
88
- // t.plan(4);
89
- // const config = new ServicesConfig();
90
- // config.merchantId = "heartlandgpsandbox";
91
- // config.accountId = "api";
92
- // config.sharedSecret = "secret";
93
- // config.refundPassword = "refund";
94
- // config.rebatePassword = "rebate";
95
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
96
- // config.timeout = 5000;
97
- // config.channel = "ECOM";
98
- // ServicesContainer.configure(config);
99
- // // create card
100
- // const card = new CreditCardData();
101
- // card.number = "4263970000005262";
102
- // card.expMonth = "12";
103
- // card.expYear = "2020";
104
- // card.cvn = "123";
105
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
106
- // card.cardHolderName = "James Mason";
107
- // // build transaction
108
- // const saleResponse = await card.authorize(1)
109
- // .withCurrency("EUR")
110
- // .execute();
111
- // t.truthy(saleResponse);
112
- // t.is("00", saleResponse.responseCode);
113
- // await throttle();
114
- // // request
115
- // const response = await saleResponse.capture(1)
116
- // .withCurrency("EUR")
117
- // .withDescription("JAVA-Settle")
118
- // .execute();
119
- // t.truthy(response);
120
- // t.is("00", response.responseCode);
121
- // });
122
- // test("JAVA_Settle_006b", async (t) => {
123
- // t.plan(4);
124
- // const config = new ServicesConfig();
125
- // config.merchantId = "heartlandgpsandbox";
126
- // config.accountId = "api";
127
- // config.sharedSecret = "secret";
128
- // config.refundPassword = "refund";
129
- // config.rebatePassword = "rebate";
130
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
131
- // config.timeout = 5000;
132
- // config.channel = "ECOM";
133
- // ServicesContainer.configure(config);
134
- // // create card
135
- // const card = new CreditCardData();
136
- // card.number = "4263970000005262";
137
- // card.expMonth = "12";
138
- // card.expYear = "2020";
139
- // card.cvn = "123";
140
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
141
- // card.cardHolderName = "James Mason";
142
- // // build transaction
143
- // const saleResponse = await card.authorize(1)
144
- // .withCurrency("EUR")
145
- // .execute();
146
- // t.truthy(saleResponse);
147
- // t.is("00", saleResponse.responseCode);
148
- // await throttle();
149
- // // request
150
- // const response = await saleResponse.capture(1)
151
- // .withCurrency("EUR")
152
- // .withDescription("JAVA-Settle")
153
- // .execute();
154
- // t.truthy(response);
155
- // t.is("00", response.responseCode);
156
- // });
157
- // test("JAVA_Settle_006c", async (t) => {
158
- // t.plan(4);
159
- // const config = new ServicesConfig();
160
- // config.merchantId = "heartlandgpsandbox";
161
- // config.accountId = "api";
162
- // config.sharedSecret = "secret";
163
- // config.refundPassword = "refund";
164
- // config.rebatePassword = "rebate";
165
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
166
- // config.timeout = 5000;
167
- // config.channel = "ECOM";
168
- // ServicesContainer.configure(config);
169
- // // create card
170
- // const card = new CreditCardData();
171
- // card.number = "4263970000005262";
172
- // card.expMonth = "12";
173
- // card.expYear = "2020";
174
- // card.cvn = "123";
175
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
176
- // card.cardHolderName = "James Mason";
177
- // // build transaction
178
- // const saleResponse = await card.authorize(1)
179
- // .withCurrency("EUR")
180
- // .execute();
181
- // t.truthy(saleResponse);
182
- // t.is("00", saleResponse.responseCode);
183
- // await throttle();
184
- // // request
185
- // const response = await saleResponse.capture(1)
186
- // .withCurrency("EUR")
187
- // .withDescription("JAVA-Settle")
188
- // .execute();
189
- // t.truthy(response);
190
- // t.is("00", response.responseCode);
191
- // });
192
- // test("JAVA_Settle_006d", async (t) => {
193
- // t.plan(4);
194
- // const config = new ServicesConfig();
195
- // config.merchantId = "heartlandgpsandbox";
196
- // config.accountId = "api";
197
- // config.sharedSecret = "secret";
198
- // config.refundPassword = "refund";
199
- // config.rebatePassword = "rebate";
200
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
201
- // config.timeout = 5000;
202
- // config.channel = "ECOM";
203
- // ServicesContainer.configure(config);
204
- // // create card
205
- // const card = new CreditCardData();
206
- // card.number = "4263970000005262";
207
- // card.expMonth = "12";
208
- // card.expYear = "2020";
209
- // card.cvn = "123";
210
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
211
- // card.cardHolderName = "James Mason";
212
- // // build transaction
213
- // const saleResponse = await card.authorize(1)
214
- // .withCurrency("EUR")
215
- // .execute();
216
- // t.truthy(saleResponse);
217
- // t.is("00", saleResponse.responseCode);
218
- // await throttle();
219
- // // request
220
- // const response = await saleResponse.capture(1)
221
- // .withCurrency("EUR")
222
- // .withDescription("JAVA-Settle")
223
- // .execute();
224
- // t.truthy(response);
225
- // t.is("00", response.responseCode);
226
- // });
227
- // test("JAVA_Settle_006e", async (t) => {
228
- // t.plan(4);
229
- // const config = new ServicesConfig();
230
- // config.merchantId = "heartlandgpsandbox";
231
- // config.accountId = "api";
232
- // config.sharedSecret = "secret";
233
- // config.refundPassword = "refund";
234
- // config.rebatePassword = "rebate";
235
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
236
- // config.timeout = 5000;
237
- // config.channel = "ECOM";
238
- // ServicesContainer.configure(config);
239
- // // create card
240
- // const card = new CreditCardData();
241
- // card.number = "4263970000005262";
242
- // card.expMonth = "12";
243
- // card.expYear = "2020";
244
- // card.cvn = "123";
245
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
246
- // card.cardHolderName = "James Mason";
247
- // // build transaction
248
- // const saleResponse = await card.authorize(1)
249
- // .withCurrency("EUR")
250
- // .execute();
251
- // t.truthy(saleResponse);
252
- // t.is("00", saleResponse.responseCode);
253
- // await throttle();
254
- // // request
255
- // const response = await saleResponse.capture(1)
256
- // .withCurrency("EUR")
257
- // .withDescription("JAVA-Settle")
258
- // .execute();
259
- // t.truthy(response);
260
- // t.is("00", response.responseCode);
261
- // });
262
- // test("JAVA_Settle_006f", async (t) => {
263
- // t.plan(4);
264
- // const config = new ServicesConfig();
265
- // config.merchantId = "heartlandgpsandbox";
266
- // config.accountId = "api";
267
- // config.sharedSecret = "secret";
268
- // config.refundPassword = "refund";
269
- // config.rebatePassword = "rebate";
270
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
271
- // config.timeout = 5000;
272
- // config.channel = "ECOM";
273
- // ServicesContainer.configure(config);
274
- // // create card
275
- // const card = new CreditCardData();
276
- // card.number = "4263970000005262";
277
- // card.expMonth = "12";
278
- // card.expYear = "2020";
279
- // card.cvn = "123";
280
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
281
- // card.cardHolderName = "James Mason";
282
- // // build transaction
283
- // const saleResponse = await card.authorize(1)
284
- // .withCurrency("EUR")
285
- // .execute();
286
- // t.truthy(saleResponse);
287
- // t.is("00", saleResponse.responseCode);
288
- // await throttle();
289
- // // request
290
- // const response = await saleResponse.capture(1)
291
- // .withCurrency("EUR")
292
- // .withDescription("JAVA-Settle")
293
- // .execute();
294
- // t.truthy(response);
295
- // t.is("00", response.responseCode);
296
- // });
297
- // test("JAVA_Settle_006g", async (t) => {
298
- // t.plan(4);
299
- // const config = new ServicesConfig();
300
- // config.merchantId = "heartlandgpsandbox";
301
- // config.accountId = "api";
302
- // config.sharedSecret = "secret";
303
- // config.refundPassword = "refund";
304
- // config.rebatePassword = "rebate";
305
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
306
- // config.timeout = 5000;
307
- // config.channel = "ECOM";
308
- // ServicesContainer.configure(config);
309
- // // create card
310
- // const card = new CreditCardData();
311
- // card.number = "4263970000005262";
312
- // card.expMonth = "12";
313
- // card.expYear = "2020";
314
- // card.cvn = "123";
315
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
316
- // card.cardHolderName = "James Mason";
317
- // // build transaction
318
- // const saleResponse = await card.authorize(1)
319
- // .withCurrency("EUR")
320
- // .execute();
321
- // t.truthy(saleResponse);
322
- // t.is("00", saleResponse.responseCode);
323
- // await throttle();
324
- // // request
325
- // const response = await saleResponse.capture(1)
326
- // .withCurrency("EUR")
327
- // .withDescription("JAVA-Settle")
328
- // .execute();
329
- // t.truthy(response);
330
- // t.is("00", response.responseCode);
331
- // });
332
- // test("JAVA_Settle_006h", async (t) => {
333
- // t.plan(4);
334
- // const config = new ServicesConfig();
335
- // config.merchantId = "heartlandgpsandbox";
336
- // config.accountId = "api";
337
- // config.sharedSecret = "secret";
338
- // config.refundPassword = "refund";
339
- // config.rebatePassword = "rebate";
340
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
341
- // config.timeout = 5000;
342
- // config.channel = "ECOM";
343
- // ServicesContainer.configure(config);
344
- // // create card
345
- // const card = new CreditCardData();
346
- // card.number = "4263970000005262";
347
- // card.expMonth = "12";
348
- // card.expYear = "2020";
349
- // card.cvn = "123";
350
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
351
- // card.cardHolderName = "James Mason";
352
- // // build transaction
353
- // const saleResponse = await card.authorize(1)
354
- // .withCurrency("EUR")
355
- // .execute();
356
- // t.truthy(saleResponse);
357
- // t.is("00", saleResponse.responseCode);
358
- // await throttle();
359
- // // request
360
- // const response = await saleResponse.capture(1)
361
- // .withCurrency("EUR")
362
- // .withDescription("JAVA-Settle")
363
- // .execute();
364
- // t.truthy(response);
365
- // t.is("00", response.responseCode);
366
- // });
367
- // test("JAVA_Settle_006i", async (t) => {
368
- // t.plan(4);
369
- // const config = new ServicesConfig();
370
- // config.merchantId = "heartlandgpsandbox";
371
- // config.accountId = "api";
372
- // config.sharedSecret = "secret";
373
- // config.refundPassword = "refund";
374
- // config.rebatePassword = "rebate";
375
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
376
- // config.timeout = 5000;
377
- // config.channel = "ECOM";
378
- // ServicesContainer.configure(config);
379
- // // create card
380
- // const card = new CreditCardData();
381
- // card.number = "4263970000005262";
382
- // card.expMonth = "12";
383
- // card.expYear = "2020";
384
- // card.cvn = "123";
385
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
386
- // card.cardHolderName = "James Mason";
387
- // // build transaction
388
- // const saleResponse = await card.authorize(1)
389
- // .withCurrency("EUR")
390
- // .execute();
391
- // t.truthy(saleResponse);
392
- // t.is("00", saleResponse.responseCode);
393
- // await throttle();
394
- // // request
395
- // const response = await saleResponse.capture(1)
396
- // .withCurrency("EUR")
397
- // .withDescription("JAVA-Settle")
398
- // .execute();
399
- // t.truthy(response);
400
- // t.is("00", response.responseCode);
401
- // });
402
- // test("JAVA_Settle_006k", async (t) => {
403
- // t.plan(4);
404
- // const config = new ServicesConfig();
405
- // config.merchantId = "heartlandgpsandbox";
406
- // config.accountId = "api";
407
- // config.sharedSecret = "secret";
408
- // config.refundPassword = "refund";
409
- // config.rebatePassword = "rebate";
410
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
411
- // config.timeout = 5000;
412
- // config.channel = "ECOM";
413
- // ServicesContainer.configure(config);
414
- // // create card
415
- // const card = new CreditCardData();
416
- // card.number = "4263970000005262";
417
- // card.expMonth = "12";
418
- // card.expYear = "2020";
419
- // card.cvn = "123";
420
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
421
- // card.cardHolderName = "James Mason";
422
- // // build transaction
423
- // const saleResponse = await card.authorize(1)
424
- // .withCurrency("EUR")
425
- // .execute();
426
- // t.truthy(saleResponse);
427
- // t.is("00", saleResponse.responseCode);
428
- // await throttle();
429
- // // request
430
- // const response = await saleResponse.capture(1)
431
- // .withCurrency("EUR")
432
- // .withDescription("JAVA-Settle")
433
- // .execute();
434
- // t.truthy(response);
435
- // t.is("00", response.responseCode);
436
- // });
437
- // test("JAVA_Settle_007a", async (t) => {
438
- // t.plan(4);
439
- // const config = new ServicesConfig();
440
- // config.merchantId = "heartlandgpsandbox";
441
- // config.accountId = "api";
442
- // config.sharedSecret = "secret";
443
- // config.refundPassword = "refund";
444
- // config.rebatePassword = "rebate";
445
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
446
- // config.timeout = 5000;
447
- // config.channel = "ECOM";
448
- // ServicesContainer.configure(config);
449
- // // create card
450
- // const card = new CreditCardData();
451
- // card.number = "4263970000005262";
452
- // card.expMonth = "12";
453
- // card.expYear = "2020";
454
- // card.cvn = "123";
455
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
456
- // card.cardHolderName = "James Mason";
457
- // // build transaction
458
- // const saleResponse = await card.authorize(1)
459
- // .withCurrency("EUR")
460
- // .execute();
461
- // t.truthy(saleResponse);
462
- // t.is("00", saleResponse.responseCode);
463
- // await throttle();
464
- // // request
465
- // const response = await saleResponse.capture(1)
466
- // .withCurrency("EUR")
467
- // .withDescription("JAVA-Settle")
468
- // .execute();
469
- // t.truthy(response);
470
- // t.is("00", response.responseCode);
471
- // });
472
- // test("JAVA_Settle_007b", async (t) => {
473
- // t.plan(4);
474
- // const config = new ServicesConfig();
475
- // config.merchantId = "heartlandgpsandbox";
476
- // config.accountId = "api";
477
- // config.sharedSecret = "secret";
478
- // config.refundPassword = "refund";
479
- // config.rebatePassword = "rebate";
480
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
481
- // config.timeout = 5000;
482
- // config.channel = "ECOM";
483
- // ServicesContainer.configure(config);
484
- // // create card
485
- // const card = new CreditCardData();
486
- // card.number = "4263970000005262";
487
- // card.expMonth = "12";
488
- // card.expYear = "2020";
489
- // card.cvn = "123";
490
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
491
- // card.cardHolderName = "James Mason";
492
- // // build transaction
493
- // const saleResponse = await card.authorize(1)
494
- // .withCurrency("EUR")
495
- // .execute();
496
- // t.truthy(saleResponse);
497
- // t.is("00", saleResponse.responseCode);
498
- // await throttle();
499
- // // request
500
- // const response = await saleResponse.capture(1)
501
- // .withCurrency("EUR")
502
- // .withDescription("JAVA-Settle")
503
- // .execute();
504
- // t.truthy(response);
505
- // t.is("00", response.responseCode);
506
- // });
507
- // test("JAVA_Settle_007c", async (t) => {
508
- // t.plan(4);
509
- // const config = new ServicesConfig();
510
- // config.merchantId = "heartlandgpsandbox";
511
- // config.accountId = "api";
512
- // config.sharedSecret = "secret";
513
- // config.refundPassword = "refund";
514
- // config.rebatePassword = "rebate";
515
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
516
- // config.timeout = 5000;
517
- // config.channel = "ECOM";
518
- // ServicesContainer.configure(config);
519
- // // create card
520
- // const card = new CreditCardData();
521
- // card.number = "4263970000005262";
522
- // card.expMonth = "12";
523
- // card.expYear = "2020";
524
- // card.cvn = "123";
525
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
526
- // card.cardHolderName = "James Mason";
527
- // // build transaction
528
- // const saleResponse = await card.authorize(1)
529
- // .withCurrency("EUR")
530
- // .execute();
531
- // t.truthy(saleResponse);
532
- // t.is("00", saleResponse.responseCode);
533
- // await throttle();
534
- // // request
535
- // const response = await saleResponse.capture(1)
536
- // .withCurrency("EUR")
537
- // .withDescription("JAVA-Settle")
538
- // .execute();
539
- // t.truthy(response);
540
- // t.is("00", response.responseCode);
541
- // });
542
- // test("JAVA_Settle_007d", async (t) => {
543
- // t.plan(4);
544
- // const config = new ServicesConfig();
545
- // config.merchantId = "heartlandgpsandbox";
546
- // config.accountId = "api";
547
- // config.sharedSecret = "secret";
548
- // config.refundPassword = "refund";
549
- // config.rebatePassword = "rebate";
550
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
551
- // config.timeout = 5000;
552
- // config.channel = "ECOM";
553
- // ServicesContainer.configure(config);
554
- // // create card
555
- // const card = new CreditCardData();
556
- // card.number = "4263970000005262";
557
- // card.expMonth = "12";
558
- // card.expYear = "2020";
559
- // card.cvn = "123";
560
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
561
- // card.cardHolderName = "James Mason";
562
- // // build transaction
563
- // const saleResponse = await card.authorize(1)
564
- // .withCurrency("EUR")
565
- // .execute();
566
- // t.truthy(saleResponse);
567
- // t.is("00", saleResponse.responseCode);
568
- // await throttle();
569
- // // request
570
- // const response = await saleResponse.capture(1)
571
- // .withCurrency("EUR")
572
- // .withDescription("JAVA-Settle")
573
- // .execute();
574
- // t.truthy(response);
575
- // t.is("00", response.responseCode);
576
- // });
577
- // test("JAVA_Settle_007e", async (t) => {
578
- // t.plan(4);
579
- // const config = new ServicesConfig();
580
- // config.merchantId = "heartlandgpsandbox";
581
- // config.accountId = "api";
582
- // config.sharedSecret = "secret";
583
- // config.refundPassword = "refund";
584
- // config.rebatePassword = "rebate";
585
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
586
- // config.timeout = 5000;
587
- // config.channel = "ECOM";
588
- // ServicesContainer.configure(config);
589
- // // create card
590
- // const card = new CreditCardData();
591
- // card.number = "4263970000005262";
592
- // card.expMonth = "12";
593
- // card.expYear = "2020";
594
- // card.cvn = "123";
595
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
596
- // card.cardHolderName = "James Mason";
597
- // // build transaction
598
- // const saleResponse = await card.authorize(1)
599
- // .withCurrency("EUR")
600
- // .execute();
601
- // t.truthy(saleResponse);
602
- // t.is("00", saleResponse.responseCode);
603
- // await throttle();
604
- // // request
605
- // const response = await saleResponse.capture(1)
606
- // .withCurrency("EUR")
607
- // .withDescription("JAVA-Settle")
608
- // .execute();
609
- // t.truthy(response);
610
- // t.is("00", response.responseCode);
611
- // });
612
- // test("JAVA_Settle_008a", async (t) => {
613
- // t.plan(4);
614
- // const config = new ServicesConfig();
615
- // config.merchantId = "heartlandgpsandbox";
616
- // config.accountId = "api";
617
- // config.sharedSecret = "secret";
618
- // config.refundPassword = "refund";
619
- // config.rebatePassword = "rebate";
620
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
621
- // config.timeout = 5000;
622
- // config.channel = "ECOM";
623
- // ServicesContainer.configure(config);
624
- // // create card
625
- // const card = new CreditCardData();
626
- // card.number = "4263970000005262";
627
- // card.expMonth = "12";
628
- // card.expYear = "2020";
629
- // card.cvn = "123";
630
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
631
- // card.cardHolderName = "James Mason";
632
- // // build transaction
633
- // const saleResponse = await card.authorize(1)
634
- // .withCurrency("EUR")
635
- // .execute();
636
- // t.truthy(saleResponse);
637
- // t.is("00", saleResponse.responseCode);
638
- // await throttle();
639
- // // request
640
- // const response = await saleResponse.capture(1)
641
- // .withCurrency("EUR")
642
- // .withDescription("JAVA-Settle")
643
- // .execute();
644
- // t.truthy(response);
645
- // t.is("00", response.responseCode);
646
- // });
647
- // test("JAVA_Settle_008b", async (t) => {
648
- // t.plan(4);
649
- // const config = new ServicesConfig();
650
- // config.merchantId = "heartlandgpsandbox";
651
- // config.accountId = "api";
652
- // config.sharedSecret = "secret";
653
- // config.refundPassword = "refund";
654
- // config.rebatePassword = "rebate";
655
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
656
- // config.timeout = 5000;
657
- // config.channel = "ECOM";
658
- // ServicesContainer.configure(config);
659
- // // create card
660
- // const card = new CreditCardData();
661
- // card.number = "4263970000005262";
662
- // card.expMonth = "12";
663
- // card.expYear = "2020";
664
- // card.cvn = "123";
665
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
666
- // card.cardHolderName = "James Mason";
667
- // // build transaction
668
- // const saleResponse = await card.authorize(1)
669
- // .withCurrency("EUR")
670
- // .execute();
671
- // t.truthy(saleResponse);
672
- // t.is("00", saleResponse.responseCode);
673
- // await throttle();
674
- // // request
675
- // const response = await saleResponse.capture(1)
676
- // .withCurrency("EUR")
677
- // .withDescription("JAVA-Settle")
678
- // .execute();
679
- // t.truthy(response);
680
- // t.is("00", response.responseCode);
681
- // });
682
- // test("JAVA_Settle_008c", async (t) => {
683
- // t.plan(4);
684
- // const config = new ServicesConfig();
685
- // config.merchantId = "heartlandgpsandbox";
686
- // config.accountId = "api";
687
- // config.sharedSecret = "secret";
688
- // config.refundPassword = "refund";
689
- // config.rebatePassword = "rebate";
690
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
691
- // config.timeout = 5000;
692
- // config.channel = "ECOM";
693
- // ServicesContainer.configure(config);
694
- // // create card
695
- // const card = new CreditCardData();
696
- // card.number = "4263970000005262";
697
- // card.expMonth = "12";
698
- // card.expYear = "2020";
699
- // card.cvn = "123";
700
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
701
- // card.cardHolderName = "James Mason";
702
- // // build transaction
703
- // const saleResponse = await card.authorize(1)
704
- // .withCurrency("EUR")
705
- // .execute();
706
- // t.truthy(saleResponse);
707
- // t.is("00", saleResponse.responseCode);
708
- // await throttle();
709
- // // request
710
- // const response = await saleResponse.capture(1)
711
- // .withCurrency("EUR")
712
- // .withDescription("JAVA-Settle")
713
- // .execute();
714
- // t.truthy(response);
715
- // t.is("00", response.responseCode);
716
- // });
717
- // test("JAVA_Settle_008d", async (t) => {
718
- // t.plan(4);
719
- // const config = new ServicesConfig();
720
- // config.merchantId = "heartlandgpsandbox";
721
- // config.accountId = "api";
722
- // config.sharedSecret = "secret";
723
- // config.refundPassword = "refund";
724
- // config.rebatePassword = "rebate";
725
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
726
- // config.timeout = 5000;
727
- // config.channel = "ECOM";
728
- // ServicesContainer.configure(config);
729
- // // create card
730
- // const card = new CreditCardData();
731
- // card.number = "4263970000005262";
732
- // card.expMonth = "12";
733
- // card.expYear = "2020";
734
- // card.cvn = "123";
735
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
736
- // card.cardHolderName = "James Mason";
737
- // // build transaction
738
- // const saleResponse = await card.authorize(1)
739
- // .withCurrency("EUR")
740
- // .execute();
741
- // t.truthy(saleResponse);
742
- // t.is("00", saleResponse.responseCode);
743
- // await throttle();
744
- // // request
745
- // const response = await saleResponse.capture(1)
746
- // .withCurrency("EUR")
747
- // .withDescription("JAVA-Settle")
748
- // .execute();
749
- // t.truthy(response);
750
- // t.is("00", response.responseCode);
751
- // });
752
- // test("JAVA_Settle_008e", async (t) => {
753
- // t.plan(4);
754
- // const config = new ServicesConfig();
755
- // config.merchantId = "heartlandgpsandbox";
756
- // config.accountId = "api";
757
- // config.sharedSecret = "secret";
758
- // config.refundPassword = "refund";
759
- // config.rebatePassword = "rebate";
760
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
761
- // config.timeout = 5000;
762
- // config.channel = "ECOM";
763
- // ServicesContainer.configure(config);
764
- // // create card
765
- // const card = new CreditCardData();
766
- // card.number = "4263970000005262";
767
- // card.expMonth = "12";
768
- // card.expYear = "2020";
769
- // card.cvn = "123";
770
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
771
- // card.cardHolderName = "James Mason";
772
- // // build transaction
773
- // const saleResponse = await card.authorize(1)
774
- // .withCurrency("EUR")
775
- // .execute();
776
- // t.truthy(saleResponse);
777
- // t.is("00", saleResponse.responseCode);
778
- // await throttle();
779
- // // request
780
- // const response = await saleResponse.capture(1)
781
- // .withCurrency("EUR")
782
- // .withDescription("JAVA-Settle")
783
- // .execute();
784
- // t.truthy(response);
785
- // t.is("00", response.responseCode);
786
- // });
787
- // test("JAVA_Settle_009a", async (t) => {
788
- // t.plan(4);
789
- // const config = new ServicesConfig();
790
- // config.merchantId = "heartlandgpsandbox";
791
- // config.accountId = "api";
792
- // config.sharedSecret = "secret";
793
- // config.refundPassword = "refund";
794
- // config.rebatePassword = "rebate";
795
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
796
- // config.timeout = 5000;
797
- // config.channel = "ECOM";
798
- // ServicesContainer.configure(config);
799
- // // create card
800
- // const card = new CreditCardData();
801
- // card.number = "4263970000005262";
802
- // card.expMonth = "12";
803
- // card.expYear = "2020";
804
- // card.cvn = "123";
805
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
806
- // card.cardHolderName = "James Mason";
807
- // // build transaction
808
- // const saleResponse = await card.authorize(1)
809
- // .withCurrency("EUR")
810
- // .execute();
811
- // t.truthy(saleResponse);
812
- // t.is("00", saleResponse.responseCode);
813
- // await throttle();
814
- // // request
815
- // const response = await saleResponse.capture(1)
816
- // .withCurrency("EUR")
817
- // .withDescription("JAVA-Settle")
818
- // .execute();
819
- // t.truthy(response);
820
- // t.is("00", response.responseCode);
821
- // });
822
- // test("JAVA_Settle_009b", async (t) => {
823
- // t.plan(4);
824
- // const config = new ServicesConfig();
825
- // config.merchantId = "heartlandgpsandbox";
826
- // config.accountId = "api";
827
- // config.sharedSecret = "secret";
828
- // config.refundPassword = "refund";
829
- // config.rebatePassword = "rebate";
830
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
831
- // config.timeout = 5000;
832
- // config.channel = "ECOM";
833
- // ServicesContainer.configure(config);
834
- // // create card
835
- // const card = new CreditCardData();
836
- // card.number = "4263970000005262";
837
- // card.expMonth = "12";
838
- // card.expYear = "2020";
839
- // card.cvn = "123";
840
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
841
- // card.cardHolderName = "James Mason";
842
- // // build transaction
843
- // const saleResponse = await card.authorize(1)
844
- // .withCurrency("EUR")
845
- // .execute();
846
- // t.truthy(saleResponse);
847
- // t.is("00", saleResponse.responseCode);
848
- // await throttle();
849
- // // request
850
- // const response = await saleResponse.capture(1)
851
- // .withCurrency("EUR")
852
- // .withDescription("JAVA-Settle")
853
- // .execute();
854
- // t.truthy(response);
855
- // t.is("00", response.responseCode);
856
- // });
857
- // test("JAVA_Settle_009c", async (t) => {
858
- // t.plan(2);
859
- // const config = new ServicesConfig();
860
- // config.merchantId = "heartlandgpsandbox";
861
- // config.accountId = "api";
862
- // config.sharedSecret = "secret";
863
- // config.refundPassword = "refund";
864
- // config.rebatePassword = "rebate";
865
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
866
- // config.timeout = 5000;
867
- // // tslint:disable:max-line-length
868
- // config.channel = "ECOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOm";
869
- // // tslint:enable:max-line-length
870
- // ServicesContainer.configure(config);
871
- // // create card
872
- // const card = new CreditCardData();
873
- // card.number = "4263970000005262";
874
- // card.expMonth = "12";
875
- // card.expYear = "2020";
876
- // card.cvn = "123";
877
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
878
- // card.cardHolderName = "James Mason";
879
- // // build transaction
880
- // // const saleResponse = await ;
881
- // // t.truthy(saleResponse);
882
- // // t.is("00", saleResponse.responseCode);
883
- // // await throttle();
884
- // // request
885
- // const error = await t.throws(
886
- // card.authorize(1)
887
- // .withCurrency("EUR")
888
- // .execute(),
889
- // GatewayError,
890
- // );
891
- // t.truthy(error.message);
892
- // });
893
- // test("JAVA_Settle_009d", async (t) => {
894
- // t.plan(2);
895
- // const config = new ServicesConfig();
896
- // config.merchantId = "heartlandgpsandbox";
897
- // config.accountId = "api";
898
- // config.sharedSecret = "secret";
899
- // config.refundPassword = "refund";
900
- // config.rebatePassword = "rebate";
901
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
902
- // config.timeout = 5000;
903
- // config.channel = "ECO#";
904
- // ServicesContainer.configure(config);
905
- // // create card
906
- // const card = new CreditCardData();
907
- // card.number = "4263970000005262";
908
- // card.expMonth = "12";
909
- // card.expYear = "2020";
910
- // card.cvn = "123";
911
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
912
- // card.cardHolderName = "James Mason";
913
- // // build transaction
914
- // // const saleResponse = await ;
915
- // // t.truthy(saleResponse);
916
- // // t.is("00", saleResponse.responseCode);
917
- // // await throttle();
918
- // // request
919
- // const error = await t.throws(
920
- // card.authorize(1)
921
- // .withCurrency("EUR")
922
- // .execute(),
923
- // GatewayError,
924
- // );
925
- // t.truthy(error.message);
926
- // });
927
- // test("JAVA_Settle_010c", async (t) => {
928
- // t.plan(4);
929
- // const config = new ServicesConfig();
930
- // config.merchantId = "heartlandgpsandbox";
931
- // config.accountId = "api";
932
- // config.sharedSecret = "secret";
933
- // config.refundPassword = "refund";
934
- // config.rebatePassword = "rebate";
935
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
936
- // config.timeout = 5000;
937
- // config.channel = "ECOM";
938
- // ServicesContainer.configure(config);
939
- // // create card
940
- // const card = new CreditCardData();
941
- // card.number = "4263970000005262";
942
- // card.expMonth = "12";
943
- // card.expYear = "2020";
944
- // card.cvn = "123";
945
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
946
- // card.cardHolderName = "James Mason";
947
- // // build transaction
948
- // const saleResponse = await card.authorize(1)
949
- // .withCurrency("EUR")
950
- // .execute();
951
- // t.truthy(saleResponse);
952
- // t.is("00", saleResponse.responseCode);
953
- // await throttle();
954
- // // request
955
- // const response = await saleResponse.capture(1)
956
- // .withCurrency("EUR")
957
- // .withDescription("JAVA-Settle")
958
- // .execute();
959
- // t.truthy(response);
960
- // t.is("00", response.responseCode);
961
- // });
962
- // test("JAVA_Settle_010d", async (t) => {
963
- // t.plan(4);
964
- // const config = new ServicesConfig();
965
- // config.merchantId = "heartlandgpsandbox";
966
- // config.accountId = "api";
967
- // config.sharedSecret = "secret";
968
- // config.refundPassword = "refund";
969
- // config.rebatePassword = "rebate";
970
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
971
- // config.timeout = 5000;
972
- // config.channel = "ECOM";
973
- // ServicesContainer.configure(config);
974
- // // create card
975
- // const card = new CreditCardData();
976
- // card.number = "4263970000005262";
977
- // card.expMonth = "12";
978
- // card.expYear = "2020";
979
- // card.cvn = "123";
980
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
981
- // card.cardHolderName = "James Mason";
982
- // // build transaction
983
- // const saleResponse = await card.authorize(1)
984
- // .withCurrency("EUR")
985
- // .execute();
986
- // t.truthy(saleResponse);
987
- // t.is("00", saleResponse.responseCode);
988
- // await throttle();
989
- // // request
990
- // const response = await saleResponse.capture(1)
991
- // .withCurrency("EUR")
992
- // .withDescription("JAVA-Settle")
993
- // .execute();
994
- // t.truthy(response);
995
- // t.is("00", response.responseCode);
996
- // });
997
- // test("JAVA_Settle_010e", async (t) => {
998
- // t.plan(4);
999
- // const config = new ServicesConfig();
1000
- // config.merchantId = "heartlandgpsandbox";
1001
- // config.accountId = "api";
1002
- // config.sharedSecret = "secret";
1003
- // config.refundPassword = "refund";
1004
- // config.rebatePassword = "rebate";
1005
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1006
- // config.timeout = 5000;
1007
- // config.channel = "ECOM";
1008
- // ServicesContainer.configure(config);
1009
- // // create card
1010
- // const card = new CreditCardData();
1011
- // card.number = "4263970000005262";
1012
- // card.expMonth = "12";
1013
- // card.expYear = "2020";
1014
- // card.cvn = "123";
1015
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1016
- // card.cardHolderName = "James Mason";
1017
- // // build transaction
1018
- // const saleResponse = await card.authorize(1)
1019
- // .withCurrency("EUR")
1020
- // .execute();
1021
- // t.truthy(saleResponse);
1022
- // t.is("00", saleResponse.responseCode);
1023
- // await throttle();
1024
- // // request
1025
- // const response = await saleResponse.capture(1)
1026
- // .withCurrency("EUR")
1027
- // .withDescription("JAVA-Settle")
1028
- // .execute();
1029
- // t.truthy(response);
1030
- // t.is("00", response.responseCode);
1031
- // });
1032
- // test("JAVA_Settle_011a", async (t) => {
1033
- // t.plan(4);
1034
- // const config = new ServicesConfig();
1035
- // config.merchantId = "heartlandgpsandbox";
1036
- // config.accountId = "api";
1037
- // config.sharedSecret = "secret";
1038
- // config.refundPassword = "refund";
1039
- // config.rebatePassword = "rebate";
1040
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1041
- // config.timeout = 5000;
1042
- // config.channel = "ECOM";
1043
- // ServicesContainer.configure(config);
1044
- // // create card
1045
- // const card = new CreditCardData();
1046
- // card.number = "4263970000005262";
1047
- // card.expMonth = "12";
1048
- // card.expYear = "2020";
1049
- // card.cvn = "123";
1050
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1051
- // card.cardHolderName = "James Mason";
1052
- // // build transaction
1053
- // const saleResponse = await card.authorize(1)
1054
- // .withCurrency("EUR")
1055
- // .execute();
1056
- // t.truthy(saleResponse);
1057
- // t.is("00", saleResponse.responseCode);
1058
- // await throttle();
1059
- // // request
1060
- // const response = await saleResponse.capture(1)
1061
- // .withCurrency("EUR")
1062
- // .withDescription("JAVA-Settle")
1063
- // .execute();
1064
- // t.truthy(response);
1065
- // t.is("00", response.responseCode);
1066
- // });
1067
- // test("JAVA_Settle_011b", async (t) => {
1068
- // t.plan(4);
1069
- // const config = new ServicesConfig();
1070
- // config.merchantId = "heartlandgpsandbox";
1071
- // config.accountId = "api";
1072
- // config.sharedSecret = "secret";
1073
- // config.refundPassword = "refund";
1074
- // config.rebatePassword = "rebate";
1075
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1076
- // config.timeout = 5000;
1077
- // config.channel = "ECOM";
1078
- // ServicesContainer.configure(config);
1079
- // // create card
1080
- // const card = new CreditCardData();
1081
- // card.number = "4263970000005262";
1082
- // card.expMonth = "12";
1083
- // card.expYear = "2020";
1084
- // card.cvn = "123";
1085
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1086
- // card.cardHolderName = "James Mason";
1087
- // // build transaction
1088
- // const saleResponse = await card.authorize(1)
1089
- // .withCurrency("EUR")
1090
- // .execute();
1091
- // t.truthy(saleResponse);
1092
- // t.is("00", saleResponse.responseCode);
1093
- // await throttle();
1094
- // // request
1095
- // const response = await saleResponse.capture(1)
1096
- // .withCurrency("EUR")
1097
- // .withDescription("JAVA-Settle")
1098
- // .execute();
1099
- // t.truthy(response);
1100
- // t.is("00", response.responseCode);
1101
- // });
1102
- // test("JAVA_Settle_011c", async (t) => {
1103
- // t.plan(4);
1104
- // const config = new ServicesConfig();
1105
- // config.merchantId = "heartlandgpsandbox";
1106
- // config.accountId = "api";
1107
- // config.sharedSecret = "secret";
1108
- // config.refundPassword = "refund";
1109
- // config.rebatePassword = "rebate";
1110
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1111
- // config.timeout = 5000;
1112
- // config.channel = "ECOM";
1113
- // ServicesContainer.configure(config);
1114
- // // create card
1115
- // const card = new CreditCardData();
1116
- // card.number = "4263970000005262";
1117
- // card.expMonth = "12";
1118
- // card.expYear = "2020";
1119
- // card.cvn = "123";
1120
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1121
- // card.cardHolderName = "James Mason";
1122
- // // build transaction
1123
- // const saleResponse = await card.authorize(1)
1124
- // .withCurrency("EUR")
1125
- // .execute();
1126
- // t.truthy(saleResponse);
1127
- // t.is("00", saleResponse.responseCode);
1128
- // await throttle();
1129
- // // request
1130
- // const response = await saleResponse.capture(1)
1131
- // .withCurrency("EUR")
1132
- // .withDescription("JAVA-Settle")
1133
- // .execute();
1134
- // t.truthy(response);
1135
- // t.is("00", response.responseCode);
1136
- // });
1137
- // test("JAVA_Settle_011d", async (t) => {
1138
- // t.plan(4);
1139
- // const config = new ServicesConfig();
1140
- // config.merchantId = "heartlandgpsandbox";
1141
- // config.accountId = "api";
1142
- // config.sharedSecret = "secret";
1143
- // config.refundPassword = "refund";
1144
- // config.rebatePassword = "rebate";
1145
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1146
- // config.timeout = 5000;
1147
- // config.channel = "ECOM";
1148
- // ServicesContainer.configure(config);
1149
- // // create card
1150
- // const card = new CreditCardData();
1151
- // card.number = "4263970000005262";
1152
- // card.expMonth = "12";
1153
- // card.expYear = "2020";
1154
- // card.cvn = "123";
1155
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1156
- // card.cardHolderName = "James Mason";
1157
- // // build transaction
1158
- // const saleResponse = await card.authorize(1)
1159
- // .withCurrency("EUR")
1160
- // .execute();
1161
- // t.truthy(saleResponse);
1162
- // t.is("00", saleResponse.responseCode);
1163
- // await throttle();
1164
- // // request
1165
- // const response = await saleResponse.capture(1)
1166
- // .withCurrency("EUR")
1167
- // .withDescription("JAVA-Settle")
1168
- // .execute();
1169
- // t.truthy(response);
1170
- // t.is("00", response.responseCode);
1171
- // });
1172
- // test("JAVA_Settle_012a", async (t) => {
1173
- // t.plan(4);
1174
- // const config = new ServicesConfig();
1175
- // config.merchantId = "heartlandgpsandbox";
1176
- // config.accountId = "api";
1177
- // config.sharedSecret = "secret";
1178
- // config.refundPassword = "refund";
1179
- // config.rebatePassword = "rebate";
1180
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1181
- // config.timeout = 5000;
1182
- // config.channel = "ECOM";
1183
- // ServicesContainer.configure(config);
1184
- // // create card
1185
- // const card = new CreditCardData();
1186
- // card.number = "4263970000005262";
1187
- // card.expMonth = "12";
1188
- // card.expYear = "2020";
1189
- // card.cvn = "123";
1190
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1191
- // card.cardHolderName = "James Mason";
1192
- // // build transaction
1193
- // const saleResponse = await card.authorize(1)
1194
- // .withCurrency("EUR")
1195
- // .execute();
1196
- // t.truthy(saleResponse);
1197
- // t.is("00", saleResponse.responseCode);
1198
- // await throttle();
1199
- // // request
1200
- // const response = await saleResponse.capture(1)
1201
- // .withCurrency("EUR")
1202
- // .withDescription("JAVA-Settle")
1203
- // .execute();
1204
- // t.truthy(response);
1205
- // t.is("00", response.responseCode);
1206
- // });
1207
- // test("JAVA_Settle_012b", async (t) => {
1208
- // t.plan(4);
1209
- // const config = new ServicesConfig();
1210
- // config.merchantId = "heartlandgpsandbox";
1211
- // config.accountId = "api";
1212
- // config.sharedSecret = "secret";
1213
- // config.refundPassword = "refund";
1214
- // config.rebatePassword = "rebate";
1215
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1216
- // config.timeout = 5000;
1217
- // config.channel = "ECOM";
1218
- // ServicesContainer.configure(config);
1219
- // // create card
1220
- // const card = new CreditCardData();
1221
- // card.number = "4263970000005262";
1222
- // card.expMonth = "12";
1223
- // card.expYear = "2020";
1224
- // card.cvn = "123";
1225
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1226
- // card.cardHolderName = "James Mason";
1227
- // // build transaction
1228
- // const saleResponse = await card.authorize(1.005)
1229
- // .withCurrency("EUR")
1230
- // .execute();
1231
- // t.truthy(saleResponse);
1232
- // t.is("00", saleResponse.responseCode);
1233
- // await throttle();
1234
- // // request
1235
- // const response = await saleResponse.capture(1.005)
1236
- // .withCurrency("EUR")
1237
- // .withDescription("JAVA-Settle")
1238
- // .execute();
1239
- // t.truthy(response);
1240
- // t.is("00", response.responseCode);
1241
- // });
1242
- // test("JAVA_Settle_012c", async (t) => {
1243
- // t.plan(4);
1244
- // const config = new ServicesConfig();
1245
- // config.merchantId = "heartlandgpsandbox";
1246
- // config.accountId = "api";
1247
- // config.sharedSecret = "secret";
1248
- // config.refundPassword = "refund";
1249
- // config.rebatePassword = "rebate";
1250
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1251
- // config.timeout = 5000;
1252
- // config.channel = "ECOM";
1253
- // ServicesContainer.configure(config);
1254
- // // create card
1255
- // const card = new CreditCardData();
1256
- // card.number = "4263970000005262";
1257
- // card.expMonth = "12";
1258
- // card.expYear = "2020";
1259
- // card.cvn = "123";
1260
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1261
- // card.cardHolderName = "James Mason";
1262
- // // build transaction
1263
- // const saleResponse = await card.authorize(10)
1264
- // .withCurrency("EUR")
1265
- // .execute();
1266
- // t.truthy(saleResponse);
1267
- // t.is("00", saleResponse.responseCode);
1268
- // await throttle();
1269
- // // request
1270
- // const error = t.throws(() =>
1271
- // saleResponse.capture()
1272
- // .withCurrency("EUR")
1273
- // .withDescription("JAVA-Settle")
1274
- // .execute(),
1275
- // BuilderError,
1276
- // );
1277
- // t.truthy(error.message);
1278
- // });
1279
- // test("JAVA_Settle_012d", async (t) => {
1280
- // t.plan(4);
1281
- // const config = new ServicesConfig();
1282
- // config.merchantId = "heartlandgpsandbox";
1283
- // config.accountId = "api";
1284
- // config.sharedSecret = "secret";
1285
- // config.refundPassword = "refund";
1286
- // config.rebatePassword = "rebate";
1287
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1288
- // config.timeout = 5000;
1289
- // config.channel = "ECOM";
1290
- // ServicesContainer.configure(config);
1291
- // // create card
1292
- // const card = new CreditCardData();
1293
- // card.number = "4263970000005262";
1294
- // card.expMonth = "12";
1295
- // card.expYear = "2020";
1296
- // card.cvn = "123";
1297
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1298
- // card.cardHolderName = "James Mason";
1299
- // // build transaction
1300
- // const saleResponse = await card.authorize(10)
1301
- // .withCurrency("EUR")
1302
- // .execute();
1303
- // t.truthy(saleResponse);
1304
- // t.is("00", saleResponse.responseCode);
1305
- // await throttle();
1306
- // // request
1307
- // const error = t.throws(() =>
1308
- // saleResponse.capture()
1309
- // .withCurrency("EUR")
1310
- // .withDescription("JAVA-Settle")
1311
- // .execute(),
1312
- // BuilderError,
1313
- // );
1314
- // t.truthy(error.message);
1315
- // });
1316
- // test("JAVA_Settle_012e", async (t) => {
1317
- // t.plan(4);
1318
- // const config = new ServicesConfig();
1319
- // config.merchantId = "heartlandgpsandbox";
1320
- // config.accountId = "api";
1321
- // config.sharedSecret = "secret";
1322
- // config.refundPassword = "refund";
1323
- // config.rebatePassword = "rebate";
1324
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1325
- // config.timeout = 5000;
1326
- // config.channel = "ECOM";
1327
- // ServicesContainer.configure(config);
1328
- // // create card
1329
- // const card = new CreditCardData();
1330
- // card.number = "4263970000005262";
1331
- // card.expMonth = "12";
1332
- // card.expYear = "2020";
1333
- // card.cvn = "123";
1334
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1335
- // card.cardHolderName = "James Mason";
1336
- // // build transaction
1337
- // const saleResponse = await card.authorize(1000)
1338
- // .withCurrency("EUR")
1339
- // .execute();
1340
- // t.truthy(saleResponse);
1341
- // t.is("00", saleResponse.responseCode);
1342
- // await throttle();
1343
- // // request
1344
- // const response = await saleResponse.capture(1000)
1345
- // .withCurrency("EUR")
1346
- // .withDescription("JAVA-Settle")
1347
- // .execute();
1348
- // t.truthy(response);
1349
- // t.is("00", response.responseCode);
1350
- // });
1351
- // test("JAVA_Settle_012f", async (t) => {
1352
- // t.plan(4);
1353
- // const config = new ServicesConfig();
1354
- // config.merchantId = "heartlandgpsandbox";
1355
- // config.accountId = "api";
1356
- // config.sharedSecret = "secret";
1357
- // config.refundPassword = "refund";
1358
- // config.rebatePassword = "rebate";
1359
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1360
- // config.timeout = 5000;
1361
- // config.channel = "ECOM";
1362
- // ServicesContainer.configure(config);
1363
- // // create card
1364
- // const card = new CreditCardData();
1365
- // card.number = "4263970000005262";
1366
- // card.expMonth = "12";
1367
- // card.expYear = "2020";
1368
- // card.cvn = "123";
1369
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1370
- // card.cardHolderName = "James Mason";
1371
- // // build transaction
1372
- // const saleResponse = await card.authorize(10)
1373
- // .withCurrency("EUR")
1374
- // .execute();
1375
- // t.truthy(saleResponse);
1376
- // t.is("00", saleResponse.responseCode);
1377
- // await throttle();
1378
- // // request
1379
- // const error = t.throws(() =>
1380
- // saleResponse.capture()
1381
- // .withCurrency("EUR")
1382
- // .withDescription("JAVA-Settle")
1383
- // .execute(),
1384
- // BuilderError,
1385
- // );
1386
- // t.truthy(error.message);
1387
- // });
1388
- // test("JAVA_Settle_013a", async (t) => {
1389
- // t.plan(4);
1390
- // const config = new ServicesConfig();
1391
- // config.merchantId = "heartlandgpsandbox";
1392
- // config.accountId = "api";
1393
- // config.sharedSecret = "secret";
1394
- // config.refundPassword = "refund";
1395
- // config.rebatePassword = "rebate";
1396
- // config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1397
- // config.timeout = 5000;
1398
- // config.channel = "ECOM";
1399
- // ServicesContainer.configure(config);
1400
- // // create card
1401
- // const card = new CreditCardData();
1402
- // card.number = "4263970000005262";
1403
- // card.expMonth = "12";
1404
- // card.expYear = "2020";
1405
- // card.cvn = "123";
1406
- // card.cvnPresenceIndicator = CvnPresenceIndicator.Present;
1407
- // card.cardHolderName = "James Mason";
1408
- // // build transaction
1409
- // const saleResponse = await card.authorize(1)
1410
- // .withCurrency("EUR")
1411
- // .execute();
1412
- // t.truthy(saleResponse);
1413
- // t.is("00", saleResponse.responseCode);
1414
- // await throttle();
1415
- // // request
1416
- // const response = await saleResponse.capture(1)
1417
- // .withCurrency("EUR")
1418
- // .withDescription("JAVA-Settle")
1419
- // .execute();
1420
- // t.truthy(response);
1421
- // t.is("00", response.responseCode);
1422
- // });
1423
- ava_1.default("JAVA_Settle_013b", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1424
- var config, card, error;
1425
- return __generator(this, function (_a) {
1426
- switch (_a.label) {
1427
- case 0:
1428
- t.plan(2);
1429
- config = new src_1.ServicesConfig();
1430
- config.merchantId = "heartlandgpsandbox";
1431
- config.accountId = "api";
1432
- config.sharedSecret = "secret";
1433
- config.refundPassword = "refund";
1434
- config.rebatePassword = "rebate";
1435
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1436
- config.timeout = 5000;
1437
- config.channel = "ECOM";
1438
- src_1.ServicesContainer.configure(config);
1439
- card = new src_1.CreditCardData();
1440
- card.number = "4263970000005262";
1441
- card.expMonth = "12";
1442
- card.expYear = "2020";
1443
- card.cvn = "123";
1444
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1445
- card.cardHolderName = "James Mason";
1446
- return [4 /*yield*/, t.throws(card
1447
- .authorize(1)
1448
- .withCurrency("EURO")
1449
- .execute(), src_1.GatewayError)];
1450
- case 1:
1451
- error = _a.sent();
1452
- t.truthy(error.message);
1453
- return [2 /*return*/];
1454
- }
1455
- });
1456
- }); });
1457
- ava_1.default("JAVA_Settle_013c", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1458
- var config, card, error;
1459
- return __generator(this, function (_a) {
1460
- switch (_a.label) {
1461
- case 0:
1462
- t.plan(2);
1463
- config = new src_1.ServicesConfig();
1464
- config.merchantId = "heartlandgpsandbox";
1465
- config.accountId = "api";
1466
- config.sharedSecret = "secret";
1467
- config.refundPassword = "refund";
1468
- config.rebatePassword = "rebate";
1469
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1470
- config.timeout = 5000;
1471
- config.channel = "ECOM";
1472
- src_1.ServicesContainer.configure(config);
1473
- card = new src_1.CreditCardData();
1474
- card.number = "4263970000005262";
1475
- card.expMonth = "12";
1476
- card.expYear = "2020";
1477
- card.cvn = "123";
1478
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1479
- card.cardHolderName = "James Mason";
1480
- return [4 /*yield*/, t.throws(card
1481
- .authorize(1)
1482
- .withCurrency("EU#")
1483
- .execute(), src_1.GatewayError)];
1484
- case 1:
1485
- error = _a.sent();
1486
- t.truthy(error.message);
1487
- return [2 /*return*/];
1488
- }
1489
- });
1490
- }); });
1491
- ava_1.default("JAVA_Settle_013d", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1492
- var config, card, saleResponse, response;
1493
- return __generator(this, function (_a) {
1494
- switch (_a.label) {
1495
- case 0:
1496
- t.plan(4);
1497
- config = new src_1.ServicesConfig();
1498
- config.merchantId = "heartlandgpsandbox";
1499
- config.accountId = "api";
1500
- config.sharedSecret = "secret";
1501
- config.refundPassword = "refund";
1502
- config.rebatePassword = "rebate";
1503
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1504
- config.timeout = 5000;
1505
- config.channel = "ECOM";
1506
- src_1.ServicesContainer.configure(config);
1507
- card = new src_1.CreditCardData();
1508
- card.number = "4263970000005262";
1509
- card.expMonth = "12";
1510
- card.expYear = "2020";
1511
- card.cvn = "123";
1512
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1513
- card.cardHolderName = "James Mason";
1514
- return [4 /*yield*/, card
1515
- .authorize(1)
1516
- .withCurrency("EUR")
1517
- .execute()];
1518
- case 1:
1519
- saleResponse = _a.sent();
1520
- t.truthy(saleResponse);
1521
- t.is("00", saleResponse.responseCode);
1522
- return [4 /*yield*/, throttle()];
1523
- case 2:
1524
- _a.sent();
1525
- return [4 /*yield*/, saleResponse
1526
- .capture(1)
1527
- .withDescription("JAVA-Settle")
1528
- .execute()];
1529
- case 3:
1530
- response = _a.sent();
1531
- t.truthy(response);
1532
- t.is("00", response.responseCode);
1533
- return [2 /*return*/];
1534
- }
1535
- });
1536
- }); });
1537
- ava_1.default("JAVA_Settle_015a", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1538
- var config, card, saleResponse, response;
1539
- return __generator(this, function (_a) {
1540
- switch (_a.label) {
1541
- case 0:
1542
- t.plan(4);
1543
- config = new src_1.ServicesConfig();
1544
- config.merchantId = "heartlandgpsandbox";
1545
- config.accountId = "api";
1546
- config.sharedSecret = "secret";
1547
- config.refundPassword = "refund";
1548
- config.rebatePassword = "rebate";
1549
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1550
- config.timeout = 5000;
1551
- config.channel = "ECOM";
1552
- src_1.ServicesContainer.configure(config);
1553
- card = new src_1.CreditCardData();
1554
- card.number = "4263970000005262";
1555
- card.expMonth = "12";
1556
- card.expYear = "2020";
1557
- card.cvn = "123";
1558
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1559
- card.cardHolderName = "James Mason";
1560
- return [4 /*yield*/, card
1561
- .authorize(1)
1562
- .withCurrency("EUR")
1563
- .execute()];
1564
- case 1:
1565
- saleResponse = _a.sent();
1566
- t.truthy(saleResponse);
1567
- t.is("00", saleResponse.responseCode);
1568
- return [4 /*yield*/, throttle()];
1569
- case 2:
1570
- _a.sent();
1571
- return [4 /*yield*/, saleResponse
1572
- .capture(1)
1573
- .withCurrency("EUR")
1574
- .withDescription("JAVA-Settle")
1575
- .execute()];
1576
- case 3:
1577
- response = _a.sent();
1578
- t.truthy(response);
1579
- t.is("00", response.responseCode);
1580
- return [2 /*return*/];
1581
- }
1582
- });
1583
- }); });
1584
- ava_1.default("JAVA_Settle_014a", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1585
- var config, card, saleResponse, response;
1586
- return __generator(this, function (_a) {
1587
- switch (_a.label) {
1588
- case 0:
1589
- t.plan(4);
1590
- config = new src_1.ServicesConfig();
1591
- config.merchantId = "heartlandgpsandbox";
1592
- config.accountId = "api";
1593
- config.sharedSecret = "secret";
1594
- config.refundPassword = "refund";
1595
- config.rebatePassword = "rebate";
1596
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1597
- config.timeout = 5000;
1598
- config.channel = "ECOM";
1599
- src_1.ServicesContainer.configure(config);
1600
- card = new src_1.CreditCardData();
1601
- card.number = "4263970000005262";
1602
- card.expMonth = "12";
1603
- card.expYear = "2020";
1604
- card.cvn = "123";
1605
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1606
- card.cardHolderName = "James Mason";
1607
- return [4 /*yield*/, card
1608
- .authorize(1)
1609
- .withCurrency("EUR")
1610
- .execute()];
1611
- case 1:
1612
- saleResponse = _a.sent();
1613
- t.truthy(saleResponse);
1614
- t.is("00", saleResponse.responseCode);
1615
- return [4 /*yield*/, throttle()];
1616
- case 2:
1617
- _a.sent();
1618
- return [4 /*yield*/, saleResponse
1619
- .capture(1)
1620
- .withCurrency("EUR")
1621
- .withDescription("JAVA-Settle")
1622
- .execute()];
1623
- case 3:
1624
- response = _a.sent();
1625
- t.truthy(response);
1626
- t.is("00", response.responseCode);
1627
- return [2 /*return*/];
1628
- }
1629
- });
1630
- }); });
1631
- ava_1.default("JAVA_Settle_014b", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1632
- var config, card, saleResponse, response;
1633
- return __generator(this, function (_a) {
1634
- switch (_a.label) {
1635
- case 0:
1636
- t.plan(4);
1637
- config = new src_1.ServicesConfig();
1638
- config.merchantId = "heartlandgpsandbox";
1639
- config.accountId = "api";
1640
- config.sharedSecret = "secret";
1641
- config.refundPassword = "refund";
1642
- config.rebatePassword = "rebate";
1643
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1644
- config.timeout = 5000;
1645
- config.channel = "ECOM";
1646
- src_1.ServicesContainer.configure(config);
1647
- card = new src_1.CreditCardData();
1648
- card.number = "4263970000005262";
1649
- card.expMonth = "12";
1650
- card.expYear = "2020";
1651
- card.cvn = "123";
1652
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1653
- card.cardHolderName = "James Mason";
1654
- return [4 /*yield*/, card
1655
- .authorize(1)
1656
- .withCurrency("EUR")
1657
- .execute()];
1658
- case 1:
1659
- saleResponse = _a.sent();
1660
- t.truthy(saleResponse);
1661
- t.is("00", saleResponse.responseCode);
1662
- return [4 /*yield*/, throttle()];
1663
- case 2:
1664
- _a.sent();
1665
- return [4 /*yield*/, saleResponse
1666
- .capture(1)
1667
- .withCurrency("EUR")
1668
- .withDescription("JAVA-Settle")
1669
- .execute()];
1670
- case 3:
1671
- response = _a.sent();
1672
- t.truthy(response);
1673
- t.is("00", response.responseCode);
1674
- return [2 /*return*/];
1675
- }
1676
- });
1677
- }); });
1678
- ava_1.default("JAVA_Settle_014c", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1679
- var config, card, saleResponse, response;
1680
- return __generator(this, function (_a) {
1681
- switch (_a.label) {
1682
- case 0:
1683
- t.plan(4);
1684
- config = new src_1.ServicesConfig();
1685
- config.merchantId = "heartlandgpsandbox";
1686
- config.accountId = "api";
1687
- config.sharedSecret = "secret";
1688
- config.refundPassword = "refund";
1689
- config.rebatePassword = "rebate";
1690
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1691
- config.timeout = 5000;
1692
- config.channel = "ECOM";
1693
- src_1.ServicesContainer.configure(config);
1694
- card = new src_1.CreditCardData();
1695
- card.number = "4263970000005262";
1696
- card.expMonth = "12";
1697
- card.expYear = "2020";
1698
- card.cvn = "123";
1699
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1700
- card.cardHolderName = "James Mason";
1701
- return [4 /*yield*/, card
1702
- .authorize(1)
1703
- .withCurrency("EUR")
1704
- .execute()];
1705
- case 1:
1706
- saleResponse = _a.sent();
1707
- t.truthy(saleResponse);
1708
- t.is("00", saleResponse.responseCode);
1709
- return [4 /*yield*/, throttle()];
1710
- case 2:
1711
- _a.sent();
1712
- return [4 /*yield*/, saleResponse
1713
- .capture(1)
1714
- .withCurrency("EUR")
1715
- .withDescription("JAVA-Settle")
1716
- .execute()];
1717
- case 3:
1718
- response = _a.sent();
1719
- t.truthy(response);
1720
- t.is("00", response.responseCode);
1721
- return [2 /*return*/];
1722
- }
1723
- });
1724
- }); });
1725
- ava_1.default("JAVA_Settle_014d", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1726
- var config, card, saleResponse, response;
1727
- return __generator(this, function (_a) {
1728
- switch (_a.label) {
1729
- case 0:
1730
- t.plan(4);
1731
- config = new src_1.ServicesConfig();
1732
- config.merchantId = "heartlandgpsandbox";
1733
- config.accountId = "api";
1734
- config.sharedSecret = "secret";
1735
- config.refundPassword = "refund";
1736
- config.rebatePassword = "rebate";
1737
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1738
- config.timeout = 5000;
1739
- config.channel = "ECOM";
1740
- src_1.ServicesContainer.configure(config);
1741
- card = new src_1.CreditCardData();
1742
- card.number = "4263970000005262";
1743
- card.expMonth = "12";
1744
- card.expYear = "2020";
1745
- card.cvn = "123";
1746
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1747
- card.cardHolderName = "James Mason";
1748
- return [4 /*yield*/, card
1749
- .authorize(1)
1750
- .withCurrency("EUR")
1751
- .execute()];
1752
- case 1:
1753
- saleResponse = _a.sent();
1754
- t.truthy(saleResponse);
1755
- t.is("00", saleResponse.responseCode);
1756
- return [4 /*yield*/, throttle()];
1757
- case 2:
1758
- _a.sent();
1759
- return [4 /*yield*/, saleResponse
1760
- .capture(1)
1761
- .withCurrency("EUR")
1762
- .withDescription("JAVA-Settle")
1763
- .execute()];
1764
- case 3:
1765
- response = _a.sent();
1766
- t.truthy(response);
1767
- t.is("00", response.responseCode);
1768
- return [2 /*return*/];
1769
- }
1770
- });
1771
- }); });
1772
- ava_1.default("JAVA_Settle_016a", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1773
- var config, card, saleResponse, response;
1774
- return __generator(this, function (_a) {
1775
- switch (_a.label) {
1776
- case 0:
1777
- t.plan(4);
1778
- config = new src_1.ServicesConfig();
1779
- config.merchantId = "heartlandgpsandbox";
1780
- config.accountId = "api";
1781
- config.sharedSecret = "secret";
1782
- config.refundPassword = "refund";
1783
- config.rebatePassword = "rebate";
1784
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1785
- config.timeout = 5000;
1786
- config.channel = "ECOM";
1787
- src_1.ServicesContainer.configure(config);
1788
- card = new src_1.CreditCardData();
1789
- card.number = "4263970000005262";
1790
- card.expMonth = "12";
1791
- card.expYear = "2020";
1792
- card.cvn = "123";
1793
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1794
- card.cardHolderName = "James Mason";
1795
- return [4 /*yield*/, card
1796
- .authorize(1)
1797
- .withCurrency("EUR")
1798
- .execute()];
1799
- case 1:
1800
- saleResponse = _a.sent();
1801
- t.truthy(saleResponse);
1802
- t.is("00", saleResponse.responseCode);
1803
- return [4 /*yield*/, throttle()];
1804
- case 2:
1805
- _a.sent();
1806
- return [4 /*yield*/, saleResponse
1807
- .capture(1)
1808
- .withCurrency("EUR")
1809
- .withDescription("JAVA-Settle")
1810
- .execute()];
1811
- case 3:
1812
- response = _a.sent();
1813
- t.truthy(response);
1814
- t.is("00", response.responseCode);
1815
- return [2 /*return*/];
1816
- }
1817
- });
1818
- }); });
1819
- ava_1.default("JAVA_Settle_016b", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1820
- var config, card, saleResponse, response;
1821
- return __generator(this, function (_a) {
1822
- switch (_a.label) {
1823
- case 0:
1824
- t.plan(4);
1825
- config = new src_1.ServicesConfig();
1826
- config.merchantId = "heartlandgpsandbox";
1827
- config.accountId = "api";
1828
- config.sharedSecret = "secret";
1829
- config.refundPassword = "refund";
1830
- config.rebatePassword = "rebate";
1831
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1832
- config.timeout = 5000;
1833
- config.channel = "ECOM";
1834
- src_1.ServicesContainer.configure(config);
1835
- card = new src_1.CreditCardData();
1836
- card.number = "4263970000005262";
1837
- card.expMonth = "12";
1838
- card.expYear = "2020";
1839
- card.cvn = "123";
1840
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1841
- card.cardHolderName = "James Mason";
1842
- return [4 /*yield*/, card
1843
- .authorize(1)
1844
- .withCurrency("EUR")
1845
- .execute()];
1846
- case 1:
1847
- saleResponse = _a.sent();
1848
- t.truthy(saleResponse);
1849
- t.is("00", saleResponse.responseCode);
1850
- return [4 /*yield*/, throttle()];
1851
- case 2:
1852
- _a.sent();
1853
- return [4 /*yield*/, saleResponse
1854
- .capture(1)
1855
- .withCurrency("EUR")
1856
- .execute()];
1857
- case 3:
1858
- response = _a.sent();
1859
- t.truthy(response);
1860
- t.is("00", response.responseCode);
1861
- return [2 /*return*/];
1862
- }
1863
- });
1864
- }); });
1865
- ava_1.default("JAVA_Settle_016c", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1866
- var config, card, saleResponse, response;
1867
- return __generator(this, function (_a) {
1868
- switch (_a.label) {
1869
- case 0:
1870
- t.plan(4);
1871
- config = new src_1.ServicesConfig();
1872
- config.merchantId = "heartlandgpsandbox";
1873
- config.accountId = "api";
1874
- config.sharedSecret = "secret";
1875
- config.refundPassword = "refund";
1876
- config.rebatePassword = "rebate";
1877
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1878
- config.timeout = 5000;
1879
- config.channel = "ECOM";
1880
- src_1.ServicesContainer.configure(config);
1881
- card = new src_1.CreditCardData();
1882
- card.number = "4263970000005262";
1883
- card.expMonth = "12";
1884
- card.expYear = "2020";
1885
- card.cvn = "123";
1886
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1887
- card.cardHolderName = "James Mason";
1888
- return [4 /*yield*/, card
1889
- .authorize(1)
1890
- .withCurrency("EUR")
1891
- .execute()];
1892
- case 1:
1893
- saleResponse = _a.sent();
1894
- t.truthy(saleResponse);
1895
- t.is("00", saleResponse.responseCode);
1896
- return [4 /*yield*/, throttle()];
1897
- case 2:
1898
- _a.sent();
1899
- return [4 /*yield*/, saleResponse
1900
- .capture(1)
1901
- .withCurrency("EUR")
1902
- // tslint:disable:max-line-length
1903
- .withDescription("JAVA-SettleAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA")
1904
- // tslint:enable:max-line-length
1905
- .execute()];
1906
- case 3:
1907
- response = _a.sent();
1908
- t.truthy(response);
1909
- t.is("00", response.responseCode);
1910
- return [2 /*return*/];
1911
- }
1912
- });
1913
- }); });
1914
- ava_1.default("JAVA_Settle_016d", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1915
- var config, card, saleResponse, response;
1916
- return __generator(this, function (_a) {
1917
- switch (_a.label) {
1918
- case 0:
1919
- t.plan(4);
1920
- config = new src_1.ServicesConfig();
1921
- config.merchantId = "heartlandgpsandbox";
1922
- config.accountId = "api";
1923
- config.sharedSecret = "secret";
1924
- config.refundPassword = "refund";
1925
- config.rebatePassword = "rebate";
1926
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1927
- config.timeout = 5000;
1928
- config.channel = "ECOM";
1929
- src_1.ServicesContainer.configure(config);
1930
- card = new src_1.CreditCardData();
1931
- card.number = "4263970000005262";
1932
- card.expMonth = "12";
1933
- card.expYear = "2020";
1934
- card.cvn = "123";
1935
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1936
- card.cardHolderName = "James Mason";
1937
- return [4 /*yield*/, card
1938
- .authorize(1)
1939
- .withCurrency("EUR")
1940
- .execute()];
1941
- case 1:
1942
- saleResponse = _a.sent();
1943
- t.truthy(saleResponse);
1944
- t.is("00", saleResponse.responseCode);
1945
- return [4 /*yield*/, throttle()];
1946
- case 2:
1947
- _a.sent();
1948
- return [4 /*yield*/, saleResponse
1949
- .capture(1)
1950
- .withCurrency("EUR")
1951
- .withDescription("JAVA-Settle###")
1952
- .execute()];
1953
- case 3:
1954
- response = _a.sent();
1955
- t.truthy(response);
1956
- t.is("00", response.responseCode);
1957
- return [2 /*return*/];
1958
- }
1959
- });
1960
- }); });
1961
- ava_1.default("JAVA_Settle_017a", function (t) { return __awaiter(void 0, void 0, void 0, function () {
1962
- var config, card, saleResponse, response;
1963
- return __generator(this, function (_a) {
1964
- switch (_a.label) {
1965
- case 0:
1966
- t.plan(4);
1967
- config = new src_1.ServicesConfig();
1968
- config.merchantId = "heartlandgpsandbox";
1969
- config.accountId = "api";
1970
- config.sharedSecret = "secret";
1971
- config.refundPassword = "refund";
1972
- config.rebatePassword = "rebate";
1973
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
1974
- config.timeout = 5000;
1975
- config.channel = "ECOM";
1976
- src_1.ServicesContainer.configure(config);
1977
- card = new src_1.CreditCardData();
1978
- card.number = "4263970000005262";
1979
- card.expMonth = "12";
1980
- card.expYear = "2020";
1981
- card.cvn = "123";
1982
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
1983
- card.cardHolderName = "James Mason";
1984
- return [4 /*yield*/, card
1985
- .authorize(1)
1986
- .withCurrency("EUR")
1987
- .execute()];
1988
- case 1:
1989
- saleResponse = _a.sent();
1990
- t.truthy(saleResponse);
1991
- t.is("00", saleResponse.responseCode);
1992
- return [4 /*yield*/, throttle()];
1993
- case 2:
1994
- _a.sent();
1995
- return [4 /*yield*/, saleResponse
1996
- .capture(1)
1997
- .withCurrency("EUR")
1998
- .withDescription("JAVA-Settle")
1999
- .execute()];
2000
- case 3:
2001
- response = _a.sent();
2002
- t.truthy(response);
2003
- t.is("00", response.responseCode);
2004
- return [2 /*return*/];
2005
- }
2006
- });
2007
- }); });
2008
- ava_1.default("JAVA_Settle_017b", function (t) { return __awaiter(void 0, void 0, void 0, function () {
2009
- var config, card, saleResponse, error;
2010
- return __generator(this, function (_a) {
2011
- switch (_a.label) {
2012
- case 0:
2013
- t.plan(4);
2014
- config = new src_1.ServicesConfig();
2015
- config.merchantId = "heartlandgpsandbox";
2016
- config.accountId = "api";
2017
- config.sharedSecret = "secreto";
2018
- config.refundPassword = "refund";
2019
- config.rebatePassword = "rebate";
2020
- config.serviceUrl = "https://api.sandbox.realexpayments.com/epage-remote.cgi";
2021
- config.timeout = 5000;
2022
- config.channel = "ECOM";
2023
- src_1.ServicesContainer.configure(config);
2024
- card = new src_1.CreditCardData();
2025
- card.number = "4263970000005262";
2026
- card.expMonth = "12";
2027
- card.expYear = "2020";
2028
- card.cvn = "123";
2029
- card.cvnPresenceIndicator = src_1.CvnPresenceIndicator.Present;
2030
- card.cardHolderName = "James Mason";
2031
- return [4 /*yield*/, card
2032
- .authorize(1)
2033
- .withCurrency("EUR")
2034
- .execute()];
2035
- case 1:
2036
- saleResponse = _a.sent();
2037
- t.truthy(saleResponse);
2038
- t.is("00", saleResponse.responseCode);
2039
- return [4 /*yield*/, throttle()];
2040
- case 2:
2041
- _a.sent();
2042
- return [4 /*yield*/, t.throws(saleResponse
2043
- .capture(1)
2044
- .withCurrency("EUR")
2045
- .withDescription("SDK-JAVA-Rebate")
2046
- .execute(), src_1.GatewayError)];
2047
- case 3:
2048
- error = _a.sent();
2049
- t.truthy(error.message);
2050
- return [2 /*return*/];
2051
- }
2052
- });
2053
- }); });