LitleOnline 9.12.0 → 10.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (129) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +7 -16
  3. data/CONTRIBUTORS +0 -0
  4. data/DESCRIPTION +2 -2
  5. data/LICENSE +1 -1
  6. data/README.md +9 -9
  7. data/Rakefile +9 -8
  8. data/SETUP.md +3 -3
  9. data/bin/Setup.rb +4 -4
  10. data/bin/sample_batch_driver.rb +1 -1
  11. data/bin/sample_driver.rb +1 -1
  12. data/lib/Communications.rb +7 -7
  13. data/lib/Configuration.rb +1 -1
  14. data/lib/EnvironmentVariables.rb +0 -0
  15. data/lib/LitleBatchRequest.rb +22 -8
  16. data/lib/LitleListeners.rb +9 -9
  17. data/lib/LitleOnline.rb +2 -2
  18. data/lib/LitleOnlineRequest.rb +16 -10
  19. data/lib/LitleRequest.rb +10 -10
  20. data/lib/LitleTransaction.rb +66 -64
  21. data/lib/LitleXmlMapper.rb +4 -9
  22. data/lib/XMLFields.rb +129 -116
  23. data/lib/cacert.pem +0 -0
  24. data/samples/Auth/LitleAuthReversalTransaction.rb +2 -2
  25. data/samples/Auth/LitleAuthorizationTransaction.rb +1 -0
  26. data/samples/Auth/LitlePaymentFullLifeCycle.rb +12 -6
  27. data/samples/Batch/AccountUpdate.rb +1 -0
  28. data/samples/Batch/SampleBatchDriver.rb +2 -1
  29. data/samples/Capture/LitleCaptureGivenAuthTransaction.rb +2 -1
  30. data/samples/Capture/LitleCaptureTransaction.rb +2 -2
  31. data/samples/Capture/LitleForceCaptureTransaction.rb +2 -1
  32. data/samples/Capture/LitlePartialCapture.rb +3 -3
  33. data/samples/Credit/LitleCreditTransaction.rb +2 -2
  34. data/samples/Credit/LitleRefundTransaction.rb +2 -1
  35. data/samples/Other/LitleAvsTransaction.rb +2 -1
  36. data/samples/Other/LitleVoidTransaction.rb +2 -1
  37. data/samples/Paypage/FullPaypageLifeCycle.rb +7 -2
  38. data/samples/Run_all.rb +0 -0
  39. data/samples/Sale/LitleSaleTransaction.rb +2 -1
  40. data/samples/Sale/SampleSaleTransaction.rb +2 -1
  41. data/test/certification/certTest1_base.rb +53 -52
  42. data/test/certification/certTest2_authenhanced.rb +16 -15
  43. data/test/certification/certTest3_authreversal.rb +16 -15
  44. data/test/certification/certTest4_echeck.rb +11 -10
  45. data/test/certification/certTest5_token.rb +2 -1
  46. data/test/certification/certTest_batchAll.rb +40 -16
  47. data/test/certification/ts_all.rb +1 -1
  48. data/test/functional/test_activate.rb +8 -9
  49. data/test/functional/test_activateReversal.rb +4 -7
  50. data/test/functional/test_auth.rb +50 -113
  51. data/test/functional/test_authReversal.rb +6 -5
  52. data/test/functional/test_balanceInquiry.rb +5 -5
  53. data/test/functional/test_batch.rb +1 -1
  54. data/test/functional/test_batchStream.rb +3 -5
  55. data/test/functional/test_cancelSubscription.rb +3 -5
  56. data/test/functional/test_capture.rb +6 -34
  57. data/test/functional/test_captureGivenAuth.rb +13 -55
  58. data/test/functional/test_configuration.rb +1 -1
  59. data/test/functional/test_createPlan.rb +3 -5
  60. data/test/functional/test_credit.rb +10 -17
  61. data/test/functional/test_deactivate.rb +5 -5
  62. data/test/functional/test_deactivateReversal.rb +4 -5
  63. data/test/functional/test_depositReversal.rb +5 -5
  64. data/test/functional/test_echeckCredit.rb +17 -13
  65. data/test/functional/test_echeckRedeposit.rb +7 -5
  66. data/test/functional/test_echeckSale.rb +42 -21
  67. data/test/functional/test_echeckVerification.rb +19 -20
  68. data/test/functional/test_echeckVoid.rb +3 -2
  69. data/test/functional/test_forceCapture.rb +16 -30
  70. data/test/functional/test_litle_requests.rb +5 -9
  71. data/test/functional/test_load.rb +5 -5
  72. data/test/functional/test_loadReversal.rb +4 -5
  73. data/test/functional/test_override.rb +3 -0
  74. data/test/functional/test_queryTransaction.rb +146 -0
  75. data/test/functional/test_refundReversal.rb +4 -5
  76. data/test/functional/test_sale.rb +94 -170
  77. data/test/functional/test_token.rb +9 -18
  78. data/test/functional/test_unload.rb +5 -5
  79. data/test/functional/test_unloadReversal.rb +5 -6
  80. data/test/functional/test_updateCardValidationNumOnToken.rb +2 -1
  81. data/test/functional/test_updatePlan.rb +4 -5
  82. data/test/functional/test_updateSubscription.rb +5 -5
  83. data/test/functional/test_wallet.rb +74 -0
  84. data/test/functional/test_xmlfields.rb +25 -10
  85. data/test/functional/ts_all.rb +4 -2
  86. data/test/unit/test_LitleAUBatch.rb +1 -1
  87. data/test/unit/test_LitleBatchRequest.rb +4 -4
  88. data/test/unit/test_LitleOnlineRequest.rb +54 -37
  89. data/test/unit/test_LitleRequest.rb +3 -4
  90. data/test/unit/test_LitleTransaction.rb +35 -6
  91. data/test/unit/test_activate.rb +21 -1
  92. data/test/unit/test_activateReversal.rb +1 -1
  93. data/test/unit/test_auth.rb +16 -55
  94. data/test/unit/test_authReversal.rb +1 -1
  95. data/test/unit/test_balanceInquiry.rb +1 -1
  96. data/test/unit/test_cancelSubscription.rb +1 -1
  97. data/test/unit/test_capture.rb +1 -27
  98. data/test/unit/test_captureGivenAuth.rb +18 -44
  99. data/test/unit/test_createPlan.rb +1 -1
  100. data/test/unit/test_credit.rb +3 -16
  101. data/test/unit/test_deactivate.rb +1 -1
  102. data/test/unit/test_deactivateReversal.rb +1 -1
  103. data/test/unit/test_depositReversal.rb +1 -1
  104. data/test/unit/test_echeckCredit.rb +1 -1
  105. data/test/unit/test_echeckRedeposit.rb +1 -1
  106. data/test/unit/test_echeckSale.rb +2 -2
  107. data/test/unit/test_echeckVerification.rb +1 -1
  108. data/test/unit/test_echeckVoid.rb +1 -1
  109. data/test/unit/test_forceCapture.rb +2 -20
  110. data/test/unit/test_load.rb +1 -1
  111. data/test/unit/test_loadReversal.rb +1 -1
  112. data/test/unit/test_queryTransaction.rb +122 -0
  113. data/test/unit/test_refundReversal.rb +1 -1
  114. data/test/unit/test_sale.rb +8 -73
  115. data/test/unit/test_token.rb +8 -15
  116. data/test/unit/test_unload.rb +1 -1
  117. data/test/unit/test_unloadReversal.rb +1 -1
  118. data/test/unit/test_updateCardValidationNumOnToken.rb +1 -1
  119. data/test/unit/test_updatePlan.rb +1 -1
  120. data/test/unit/test_updateSubscription.rb +1 -1
  121. data/test/unit/test_wallet.rb +262 -0
  122. data/test/unit/test_xmlfields.rb +1 -1
  123. data/test/unit/ts_unit.rb +3 -3
  124. metadata +15 -16
  125. data/temp.xml +0 -21
  126. data/test/functional/test_fraudCheck.rb +0 -77
  127. data/test/functional/test_utf8.rb +0 -44
  128. data/test/unit/test_LitleXmlMapper.rb +0 -136
  129. data/test/unit/test_fraudCheck.rb +0 -45
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -32,6 +32,7 @@ module LitleOnline
32
32
  def test_simple_card_happy
33
33
  hash = {
34
34
  'merchantId' => '101',
35
+ 'id' =>'test',
35
36
  'version'=>'8.8',
36
37
  'reportGroup'=>'Planets',
37
38
  'orderId' =>'1001',
@@ -41,7 +42,7 @@ def test_simple_card_happy
41
42
  'type'=>'VI',
42
43
  'number' =>'4100000000000001',
43
44
  'expDate' =>'1210'
44
- }
45
+ }
45
46
  }
46
47
 
47
48
  response= LitleOnlineRequest.new.activate(hash)
@@ -52,6 +53,7 @@ def test_simple_virtualGiftCard_happy
52
53
  hash = {
53
54
  'merchantId' => '101',
54
55
  'version'=>'8.8',
56
+ 'id' =>'test',
55
57
  'reportGroup'=>'Planets',
56
58
  'orderId' =>'1001',
57
59
  'amount' =>'500',
@@ -59,7 +61,7 @@ def test_simple_virtualGiftCard_happy
59
61
  'virtualGiftCard'=>{
60
62
  'accountNumberLength'=>'13',
61
63
  'giftCardBin'=>'giftCardBinString'
62
- }
64
+ }
63
65
  }
64
66
 
65
67
  response= LitleOnlineRequest.new.activate(hash)
@@ -70,6 +72,7 @@ def test_simple_virtualGiftCard_happy
70
72
  hash = {
71
73
  'merchantId' => '101',
72
74
  'version'=>'8.8',
75
+ 'id' =>'test',
73
76
  'reportGroup'=>'Planets',
74
77
  'amount' =>'500',
75
78
  'orderId' =>'1001',
@@ -93,12 +96,8 @@ def test_simple_virtualGiftCard_happy
93
96
  'amount' =>'500',
94
97
  }
95
98
 
96
- #Get exceptions
97
- exception = assert_raise(RuntimeError){
98
- LitleOnlineRequest.new.activate(hash)
99
- }
100
- #Test
101
- assert(exception.message =~ /Error validating xml data against the schema/)
99
+ response= LitleOnlineRequest.new.activate(hash)
100
+ assert(response.message =~ /Error validating xml data against the schema/)
102
101
  end
103
102
  end
104
103
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -32,6 +32,7 @@ module LitleOnline
32
32
  def test_simple
33
33
  hash = {
34
34
  'merchantId' => '101',
35
+ 'id' => 'test',
35
36
  'version'=>'8.8',
36
37
  'reportGroup'=>'Planets',
37
38
  'litleTxnId' =>'5000'
@@ -49,12 +50,8 @@ def test_simple
49
50
  'reportGroup'=>'Planets',
50
51
  }
51
52
 
52
- #Get exceptions
53
- exception = assert_raise(RuntimeError){
54
- LitleOnlineRequest.new.activate_reversal(hash)
55
- }
56
- #Test
57
- assert(exception.message =~ /Error validating xml data against the schema/)
53
+ response= LitleOnlineRequest.new.activate_reversal(hash)
54
+ assert(response.message =~ /Error validating xml data against the schema/)
58
55
  end
59
56
  end
60
57
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -31,6 +31,7 @@ module LitleOnline
31
31
  def test_simple_auth_with_card
32
32
  hash = {
33
33
  'merchantId' => '101',
34
+ 'id' => 'test',
34
35
  'version'=>'8.8',
35
36
  'reportGroup'=>'Planets',
36
37
  'orderId'=>'12344',
@@ -48,6 +49,7 @@ module LitleOnline
48
49
  def test_simple_auth_with_paypal
49
50
  hash = {
50
51
  'merchantId' => '101',
52
+ 'id' => 'test',
51
53
  'version'=>'8.8',
52
54
  'reportGroup'=>'Planets',
53
55
  'amount'=>'106',
@@ -65,6 +67,7 @@ module LitleOnline
65
67
  def test_simple_auth_with_applepay_and_secondaryAmount
66
68
  hash = {
67
69
  'merchantId' => '101',
70
+ 'id' => 'test',
68
71
  'version'=>'8.8',
69
72
  'reportGroup'=>'Planets',
70
73
  'orderId'=>'12344',
@@ -80,7 +83,9 @@ module LitleOnline
80
83
  'transactionId'=>'1234'
81
84
  },
82
85
  'signature' =>'1',
83
- 'version'=>'1.0.0'
86
+ # RUby SDK XML 10
87
+ #'version'=>'1'
88
+ 'version'=>'1000000'
84
89
  }}
85
90
  response= LitleOnlineRequest.new.authorization(hash)
86
91
  assert_equal('Insufficient Funds', response.authorizationResponse.message)
@@ -90,6 +95,7 @@ module LitleOnline
90
95
  def test_illegal_order_source
91
96
  hash = {
92
97
  'merchantId' => '101',
98
+ 'id' => 'test',
93
99
  'version'=>'8.8',
94
100
  'reportGroup'=>'Planets',
95
101
  'orderId'=>'12344',
@@ -100,19 +106,14 @@ module LitleOnline
100
106
  'number' =>'4100000000000001',
101
107
  'expDate' =>'1210'
102
108
  }}
103
-
104
- #Get exceptions
105
- exception = assert_raise(RuntimeError){
106
- LitleOnlineRequest.new.authorization(hash)
107
- }
108
- #Test
109
- assert(exception.message =~ /Error validating xml data against the schema/)
110
-
109
+ response= LitleOnlineRequest.new.authorization(hash)
110
+ assert(response.message =~ /Error validating xml data against the schema/)
111
111
  end
112
112
 
113
113
  def test_fields_out_of_order
114
114
  hash = {
115
115
  'merchantId' => '101',
116
+ 'id' => 'test',
116
117
  'version'=>'8.8',
117
118
  'reportGroup'=>'Planets',
118
119
  'orderId'=>'12344',
@@ -131,6 +132,7 @@ module LitleOnline
131
132
  def test_invalid_field
132
133
  hash = {
133
134
  'merchantId' => '101',
135
+ 'id' => 'test',
134
136
  'version'=>'8.8',
135
137
  'reportGroup'=>'Planets',
136
138
  'orderId'=>'12344',
@@ -149,6 +151,7 @@ module LitleOnline
149
151
  def test_no_order_id
150
152
  hash = {
151
153
  'merchantId' => '101',
154
+ 'id' => 'test',
152
155
  'version'=>'8.8',
153
156
  'reportGroup'=>'Planets',
154
157
  'amount'=>'106',
@@ -158,17 +161,14 @@ module LitleOnline
158
161
  'number' =>'4100000000000001',
159
162
  'expDate' =>'1210'
160
163
  }}
161
- #Get exceptions
162
- exception = assert_raise(RuntimeError){
163
- LitleOnlineRequest.new.authorization(hash)
164
- }
165
- #Test
166
- assert(exception.message =~ /Error validating xml data against the schema/)
164
+ response= LitleOnlineRequest.new.authorization(hash)
165
+ assert(response.message =~ /Error validating xml data against the schema/)
167
166
  end
168
167
 
169
168
  def test_no_amount
170
169
  hash = {
171
170
  'merchantId' => '101',
171
+ 'id' => 'test',
172
172
  'version'=>'8.8',
173
173
  'reportGroup'=>'Planets',
174
174
  'orderId'=>'12344',
@@ -178,17 +178,14 @@ module LitleOnline
178
178
  'number' =>'4100000000000001',
179
179
  'expDate' =>'1210'
180
180
  }}
181
- #Get exceptions
182
- exception = assert_raise(RuntimeError){
183
- LitleOnlineRequest.new.authorization(hash)
184
- }
185
- #Test
186
- assert(exception.message =~ /Error validating xml data against the schema/)
181
+ response= LitleOnlineRequest.new.authorization(hash)
182
+ assert(response.message =~ /Error validating xml data against the schema/)
187
183
  end
188
184
 
189
185
  def test_no_order_source
190
186
  hash = {
191
187
  'merchantId' => '101',
188
+ 'id' => 'test',
192
189
  'version'=>'8.8',
193
190
  'reportGroup'=>'Planets',
194
191
  # 'litleTxnId'=>'123456',
@@ -199,12 +196,8 @@ module LitleOnline
199
196
  'number' =>'4100000000000001',
200
197
  'expDate' =>'1210'
201
198
  }}
202
- #Get exceptions
203
- exception = assert_raise(RuntimeError){
204
- LitleOnlineRequest.new.authorization(hash)
205
- }
206
- #Test
207
- assert(exception.message =~ /Error validating xml data against the schema/)
199
+ response= LitleOnlineRequest.new.authorization(hash)
200
+ assert(response.message =~ /Error validating xml data against the schema/)
208
201
  end
209
202
 
210
203
  def test_authorization_missing_attributes
@@ -219,16 +212,12 @@ module LitleOnline
219
212
  'expDate' =>'1210'
220
213
  }}
221
214
 
222
- #Get exceptions
223
- exception = assert_raise(RuntimeError){
224
- LitleOnlineRequest.new.authorization(hash)
225
- }
226
- #Test
227
- assert(exception.message =~ /Error validating xml data against the schema/)
215
+ response= LitleOnlineRequest.new.authorization(hash)
216
+
228
217
  end
229
218
 
230
219
  def test_orderId_required
231
- hash = {
220
+ start_hash = {
232
221
  'merchantId'=>'101',
233
222
  'reportGroup'=>'Planets',
234
223
  'amount'=>'101',
@@ -238,20 +227,18 @@ module LitleOnline
238
227
  'number' => '1111222233334444'
239
228
  }
240
229
  }
241
- #Get exceptions
242
- exception = assert_raise(RuntimeError){
243
- LitleOnlineRequest.new.authorization(hash)
244
- }
245
- #Test
246
- assert(exception.message =~ /Error validating xml data against the schema/)
247
-
248
- response = LitleOnlineRequest.new.authorization(hash.merge({'orderId'=>'1234'}))
230
+ response= LitleOnlineRequest.new.authorization(start_hash)
231
+ assert(response.message =~ /Error validating xml data against the schema/)
232
+ #SDK XML 10
233
+ #response = LitleOnlineRequest.new.authorization(start_hash.merge({'orderId'=>'1234'}))
234
+ response = LitleOnlineRequest.new.authorization(start_hash.merge({'orderId'=>'1234','id'=>'test'}))
249
235
  assert_equal('000', response.authorizationResponse.response)
250
236
  end
251
237
 
252
238
  def test_ssn_optional
253
239
  start_hash = {
254
240
  'orderId'=>'12344',
241
+ 'id' => 'test',
255
242
  'merchantId'=>'101',
256
243
  'reportGroup'=>'Planets',
257
244
  'amount'=>'101',
@@ -271,6 +258,7 @@ module LitleOnline
271
258
  def test_simple_auth_with_paypage
272
259
  hash = {
273
260
  'orderId'=>'12344',
261
+ 'id' => 'test',
274
262
  'amount'=>'106',
275
263
  'orderSource'=>'ecommerce',
276
264
  'paypage'=>{
@@ -287,6 +275,7 @@ module LitleOnline
287
275
  def test_simple_auth_with_advanced_fraud_checks
288
276
  hash = {
289
277
  'merchantId' => '101',
278
+ 'id' => 'test',
290
279
  'version'=>'8.8',
291
280
  'reportGroup'=>'Planets',
292
281
  'orderId'=>'12355',
@@ -306,6 +295,7 @@ module LitleOnline
306
295
  def test_simple_auth_with_mpos
307
296
  hash = {
308
297
  'orderId'=>'12344',
298
+ 'id' => 'test',
309
299
  'amount'=>'106',
310
300
  'orderSource'=>'ecommerce',
311
301
  'mpos'=>
@@ -321,81 +311,28 @@ module LitleOnline
321
311
  assert_equal('000', response.authorizationResponse.response)
322
312
  end
323
313
 
324
- def test_simple_auth_with_processingType_originalNetworkTransactionId_originalTransactionAmount
314
+ #SDK XML 10
315
+ def test_simple_auth_with_wallet1
325
316
  hash = {
326
317
  'merchantId' => '101',
318
+ 'id' => 'test',
327
319
  'version'=>'8.8',
328
320
  'reportGroup'=>'Planets',
329
- 'orderId'=>'12355',
330
321
  'amount'=>'106',
322
+ 'orderId'=>'123456',
331
323
  'orderSource'=>'ecommerce',
332
- 'card'=>{
333
- 'type'=>'VI',
334
- 'number' =>'4100000000000000',
335
- 'expDate' =>'1210'
336
- },
337
- 'processingType' => 'initialInstallment',
338
- 'originalNetworkTransactionId' => '9876543210',
339
- 'originalTransactionAmount' => '536981'
340
- }
341
- response= LitleOnlineRequest.new.authorization(hash)
342
- assert_equal('000', response.authorizationResponse.response)
343
- assert_equal('63225578415568556365452427825', response.authorizationResponse.networkTransactionId)
344
- end
345
-
346
- def test_simple_auth_with_wallet
347
- hash = {
348
- 'merchantId' => '101',
349
- 'version'=>'8.8',
350
- 'reportGroup'=>'Planets',
351
- 'id'=>'12345',
352
- 'orderId'=>'67890',
353
- 'amount'=>'10000',
354
- 'orderSource'=>'ecommerce',
355
- 'processingType' => 'initialInstallment',
356
- 'originalNetworkTransactionId' => '9876543210',
357
- 'originalTransactionAmount' => '536981',
358
- 'card'=>{
359
- 'type'=>'VI',
360
- 'number' =>'4100000000000000',
361
- 'expDate' =>'1215'
362
- },
363
- 'wallet'=>{
364
- 'walletSourceType'=>'VisaCheckout',
365
- 'walletSourceTypeId' => 'VCIND'
366
- }
367
- }
368
- response= LitleOnlineRequest.new.authorization(hash)
369
- assert_equal('000', response.authorizationResponse.response)
370
- assert_equal('63225578415568556365452427825', response.authorizationResponse.networkTransactionId)
371
- end
372
-
373
- def test_simple_auth_with_wallet_CardSuffixResponse
374
- hash = {
375
- 'merchantId' => '101',
376
- 'version'=>'8.8',
377
- 'reportGroup'=>'Planets',
378
- 'id'=>'12345',
379
- 'orderId'=>'67890',
380
- 'amount'=>'10000',
381
- 'orderSource'=>'ecommerce',
382
- 'processingType' => 'initialInstallment',
383
- 'originalNetworkTransactionId' => '9876543210',
384
- 'originalTransactionAmount' => '536981',
385
- 'card'=>{
386
- 'type'=>'MC',
387
- 'number' =>'5400700000000000',
388
- 'expDate' =>'1215'
389
- },
390
- 'wallet'=>{
391
- 'walletSourceType'=>'MasterPass',
392
- 'walletSourceTypeId' => 'MasterPass'
393
- }
394
- }
395
- response= LitleOnlineRequest.new.authorization(hash)
396
- assert_equal('000', response.authorizationResponse.response)
397
- assert_equal('123456', response.authorizationResponse.cardSuffix)
398
- end
399
-
324
+ 'paypal'=>
325
+ {
326
+ 'payerId'=>'1234',
327
+ 'token'=>'1234',
328
+ 'transactionId'=>'123456'
329
+ },
330
+ 'wallet'=> {
331
+ 'walletSourceType' => 'MasterPass',
332
+ 'walletSourceTypeId' => '102'
333
+ }}
334
+ response= LitleOnlineRequest.new.authorization(hash)
335
+ assert_equal 'Valid Format', response.message
336
+ end
400
337
  end
401
338
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -31,6 +31,7 @@ module LitleOnline
31
31
  hash = {
32
32
  'merchantId' => '101',
33
33
  'version'=>'8.8',
34
+ 'id'=>'test',
34
35
  'reportGroup'=>'Planets',
35
36
  'litleTxnId'=>'12345678000',
36
37
  'amount'=>'106',
@@ -44,6 +45,7 @@ module LitleOnline
44
45
  hash = {
45
46
  'merchantId' => '101',
46
47
  'version'=>'8.8',
48
+ 'id'=>'test',
47
49
  'litleTxnId'=>'12345000',
48
50
  'payPalNotes'=>'Notes',
49
51
  'amount'=>'106',
@@ -57,14 +59,13 @@ module LitleOnline
57
59
  hash = {
58
60
  'merchantId' => '101',
59
61
  'version'=>'8.8',
62
+ 'id'=>'test',
60
63
  'reportGroup'=>'12345678',
61
64
  'amount'=>'106',
62
65
  'payPalNotes'=>'Notes'
63
66
  }
64
- #Get exceptions
65
- exception = assert_raise(RuntimeError){LitleOnlineRequest.new.auth_reversal(hash)}
66
- #Test
67
- assert(exception.message =~ /Error validating xml data against the schema/)
67
+ response= LitleOnlineRequest.new.auth_reversal(hash)
68
+ assert(response.message =~ /Error validating xml data against the schema/)
68
69
  end
69
70
 
70
71
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- Copyright (c) 2017 Vantiv eCommerce
2
+ Copyright (c) 2012 Litle & Co.
3
3
 
4
4
  Permission is hereby granted, free of charge, to any person
5
5
  obtaining a copy of this software and associated documentation
@@ -33,6 +33,7 @@ def test_simple_happy
33
33
  hash = {
34
34
  'merchantId' => '101',
35
35
  'version'=>'8.8',
36
+ 'id'=>'test',
36
37
  'reportGroup'=>'Planets',
37
38
  'orderId' =>'1001',
38
39
  'orderSource' =>'ecommerce',
@@ -51,6 +52,7 @@ def test_simple_happy
51
52
  hash = {
52
53
  'merchantId' => '101',
53
54
  'version'=>'8.8',
55
+ 'id'=>'test',
54
56
  'reportGroup'=>'Planets',
55
57
  'orderSource' =>'ecommerce',
56
58
  'orderId' =>'1001',
@@ -73,10 +75,8 @@ def test_simple_happy
73
75
  'amount' =>'500',
74
76
  }
75
77
 
76
- #Get exceptions
77
- exception = assert_raise(RuntimeError){LitleOnlineRequest.new.balance_inquiry(hash)}
78
- #Test
79
- assert(exception.message =~ /Error validating xml data against the schema/)
78
+ response= LitleOnlineRequest.new.balance_inquiry(hash)
79
+ assert(response.message =~ /Error validating xml data against the schema/)
80
80
  end
81
81
  end
82
82
  end