LitleOnline 8.10.0 → 8.10.1

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 (38) hide show
  1. data/Rakefile +1 -1
  2. data/lib/Communications.rb +3 -4
  3. data/lib/Configuration.rb +1 -1
  4. data/lib/LitleOnlineRequest.rb +170 -139
  5. data/lib/XMLFields.rb +29 -29
  6. data/test/certification/certTest1_base.rb +602 -606
  7. data/test/certification/certTest2_authenhanced.rb +6 -6
  8. data/test/certification/certTest3_authreversal.rb +29 -30
  9. data/test/certification/certTest4_echeck.rb +13 -16
  10. data/test/certification/certTest5_token.rb +11 -31
  11. data/test/functional/test_auth.rb +6 -6
  12. data/test/functional/test_authReversal.rb +6 -6
  13. data/test/functional/test_capture.rb +3 -3
  14. data/test/functional/test_captureGivenAuth.rb +12 -12
  15. data/test/functional/test_credit.rb +7 -7
  16. data/test/functional/test_echeckCredit.rb +11 -11
  17. data/test/functional/test_echeckRedeposit.rb +8 -8
  18. data/test/functional/test_echeckSale.rb +34 -32
  19. data/test/functional/test_echeckVerification.rb +8 -8
  20. data/test/functional/test_forceCapture.rb +8 -8
  21. data/test/functional/test_sale.rb +9 -11
  22. data/test/functional/test_token.rb +12 -12
  23. data/test/functional/test_xmlfields.rb +18 -18
  24. data/test/unit/test_LitleOnlineRequest.rb +26 -17
  25. data/test/unit/test_auth.rb +22 -10
  26. data/test/unit/test_authReversal.rb +2 -2
  27. data/test/unit/test_capture.rb +1 -1
  28. data/test/unit/test_captureGivenAuth.rb +6 -6
  29. data/test/unit/test_credit.rb +4 -7
  30. data/test/unit/test_echeckCredit.rb +2 -2
  31. data/test/unit/test_echeckRedeposit.rb +8 -8
  32. data/test/unit/test_echeckSale.rb +2 -2
  33. data/test/unit/test_echeckVerification.rb +8 -8
  34. data/test/unit/test_forceCapture.rb +8 -8
  35. data/test/unit/test_sale.rb +9 -9
  36. data/test/unit/test_token.rb +4 -4
  37. data/test/unit/test_xmlfields.rb +7 -9
  38. metadata +12 -12
@@ -155,7 +155,7 @@ class Litle_certTest2 < Test::Unit::TestCase
155
155
  assert_equal('PAYROLL', auth_response.authorizationResponse.enhancedAuthResponse.fundingSource.prepaidCardType)
156
156
  end
157
157
 
158
- def test_2118698
158
+ def test_21
159
159
  customer_hash = {
160
160
  'orderId' => '21',
161
161
  'amount' => '5000',
@@ -431,7 +431,7 @@ class Litle_certTest2 < Test::Unit::TestCase
431
431
  #test 32B
432
432
  authReversal_hash = {'litleTxnId' => authorization_response.authorizationResponse.litleTxnId}
433
433
  hash1b = authReversal_hash.merge(@@merchant_hash)
434
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1b)
434
+ authReversal_response = LitleOnlineRequest.new.auth_reversal(hash1b)
435
435
  assert_equal('111', authReversal_response.authReversalResponse.response)
436
436
  assert_equal('Authorization amount has already been depleted', authReversal_response.authReversalResponse.message)
437
437
  end
@@ -467,7 +467,7 @@ class Litle_certTest2 < Test::Unit::TestCase
467
467
  #test 33A
468
468
  authReversal_hash = {'litleTxnId' => authorization_response.authorizationResponse.litleTxnId}
469
469
  hash1b = authReversal_hash.merge(@@merchant_hash)
470
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1b)
470
+ authReversal_response = LitleOnlineRequest.new.auth_reversal(hash1b)
471
471
  assert_equal('000', authReversal_response.authReversalResponse.response)
472
472
  assert_equal('Approved', authReversal_response.authReversalResponse.message)
473
473
  end
@@ -501,7 +501,7 @@ class Litle_certTest2 < Test::Unit::TestCase
501
501
  #test 34A
502
502
  authReversal_hash = {'litleTxnId' => authorization_response.authorizationResponse.litleTxnId}
503
503
  hash1b = authReversal_hash.merge(@@merchant_hash)
504
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1b)
504
+ authReversal_response = LitleOnlineRequest.new.auth_reversal(hash1b)
505
505
  assert_equal('000', authReversal_response.authReversalResponse.response)
506
506
  assert_equal('Approved', authReversal_response.authReversalResponse.message)
507
507
  end
@@ -540,7 +540,7 @@ class Litle_certTest2 < Test::Unit::TestCase
540
540
  #test 35B
541
541
  authReversal_hash = {'litleTxnId' => authorization_response.authorizationResponse.litleTxnId, 'amount' => '20020'}
542
542
  hash1b = authReversal_hash.merge(@@merchant_hash)
543
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1b)
543
+ authReversal_response = LitleOnlineRequest.new.auth_reversal(hash1b)
544
544
  assert_equal('000', authReversal_response.authReversalResponse.response)
545
545
  assert_equal('Approved', authReversal_response.authReversalResponse.message)
546
546
  end
@@ -563,7 +563,7 @@ class Litle_certTest2 < Test::Unit::TestCase
563
563
  #test 36A
564
564
  authReversal_hash = {'litleTxnId' => authorization_response.authorizationResponse.litleTxnId, 'amount' => '10000'}
565
565
  hash1b = authReversal_hash.merge(@@merchant_hash)
566
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1b)
566
+ authReversal_response = LitleOnlineRequest.new.auth_reversal(hash1b)
567
567
  assert_equal('336', authReversal_response.authReversalResponse.response)
568
568
  assert_equal('Reversal Amount does not match Authorization amount', authReversal_response.authReversalResponse.message)
569
569
  end
@@ -40,12 +40,12 @@ class Litle_certTest3 < Test::Unit::TestCase
40
40
  assert_equal('000', capture_response.captureResponse.response)
41
41
  assert_equal('Approved', capture_response.captureResponse.message)
42
42
 
43
- # #test 32B
44
- # authR_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId }
45
- # hash1b = authR_hash.merge(@@merchant_hash)
46
- # authR_response = LitleOnlineRequest.new.authReversal(hash1b)
47
- # assert_equal('111', authR_response.authReversalResponse.response)
48
- # assert_equal('Authorization amount has already been depleted', authR_response.authReversalResponse.message)
43
+ #test 32B
44
+ auth_r_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId }
45
+ hash1b = auth_r_hash.merge(@@merchant_hash)
46
+ auth_r_response = LitleOnlineRequest.new.auth_reversal(hash1b)
47
+ assert_equal('111', auth_r_response.authReversalResponse.response)
48
+ assert_equal('Authorization amount has already been depleted', auth_r_response.authReversalResponse.message)
49
49
  end
50
50
 
51
51
  def test_33
@@ -76,12 +76,12 @@ class Litle_certTest3 < Test::Unit::TestCase
76
76
  assert_equal('10', auth_response.authorizationResponse.fraudResult.avsResult)
77
77
  assert_equal('M', auth_response.authorizationResponse.fraudResult.cardValidationResult)
78
78
 
79
- # #test 33A
80
- # authReversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId}
81
- # hash1a = authReversal_hash.merge(@@merchant_hash)
82
- # authReversal_response = LitleOnlineRequest.new.authReversal(hash1a)
83
- # assert_equal('000', authReversal_response.authReversalResponse.response)
84
- # assert_equal('Approved', authReversal_response.authReversalResponse.message)
79
+ #test 33A
80
+ auth_reversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId}
81
+ hash1a = auth_reversal_hash.merge(@@merchant_hash)
82
+ auth_reversal_response = LitleOnlineRequest.new.auth_reversal(hash1a)
83
+ assert_equal('000', auth_reversal_response.authReversalResponse.response)
84
+ assert_equal('Approved', auth_reversal_response.authReversalResponse.message)
85
85
  end
86
86
 
87
87
  def test_34
@@ -110,12 +110,12 @@ class Litle_certTest3 < Test::Unit::TestCase
110
110
  assert_equal('10', auth_response.authorizationResponse.fraudResult.avsResult)
111
111
  assert_equal('M', auth_response.authorizationResponse.fraudResult.cardValidationResult)
112
112
 
113
- # #test 34A
114
- # authReversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId}
115
- # hash1a = authReversal_hash.merge(@@merchant_hash)
116
- # authReversal_response = LitleOnlineRequest.new.authReversal(hash1a)
117
- # assert_equal('000', authReversal_response.authReversalResponse.response)
118
- # assert_equal('Approved', authReversal_response.authReversalResponse.message)
113
+ #test 34A
114
+ auth_reversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId}
115
+ hash1a = auth_reversal_hash.merge(@@merchant_hash)
116
+ auth_reversal_response = LitleOnlineRequest.new.auth_reversal(hash1a)
117
+ assert_equal('000', auth_reversal_response.authReversalResponse.response)
118
+ assert_equal('Approved', auth_reversal_response.authReversalResponse.message)
119
119
  end
120
120
 
121
121
  def test_35
@@ -149,13 +149,12 @@ class Litle_certTest3 < Test::Unit::TestCase
149
149
  assert_equal('000', capture_response.captureResponse.response)
150
150
  assert_equal('Approved', capture_response.captureResponse.message)
151
151
 
152
- # # #test 35B
153
- # authReversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId, 'amount' => '20020'}
154
- # #authReversal_hash = {'litleTxnId' => capture_response.captureResponse.litleTxnId, 'amount' => '20020'}
155
- # hash2a = authReversal_hash.merge(@@merchant_hash)
156
- # authReversal_response = LitleOnlineRequest.new.authReversal(hash2a)
157
- # assert_equal('000', authReversal_response.authReversalResponse.response)
158
- # assert_equal('Approved', authReversal_response.authReversalResponse.message)
152
+ # #test 35B
153
+ auth_reversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId, 'amount' => '20020'}
154
+ hash2a = auth_reversal_hash.merge(@@merchant_hash)
155
+ auth_reversal_response = LitleOnlineRequest.new.auth_reversal(hash2a)
156
+ assert_equal('000', auth_reversal_response.authReversalResponse.response)
157
+ assert_equal('Approved', auth_reversal_response.authReversalResponse.message)
159
158
  end
160
159
 
161
160
  def test_36
@@ -174,11 +173,11 @@ class Litle_certTest3 < Test::Unit::TestCase
174
173
  assert_equal('Approved', auth_response.authorizationResponse.message)
175
174
 
176
175
  #test 36A
177
- authReversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId, 'amount' => '10000'}
178
- hash1a = authReversal_hash.merge(@@merchant_hash)
179
- authReversal_response = LitleOnlineRequest.new.authReversal(hash1a)
180
- assert_equal('336', authReversal_response.authReversalResponse.response)
181
- assert_equal('Reversal Amount does not match Authorization amount', authReversal_response.authReversalResponse.message)
176
+ auth_reversal_hash = {'litleTxnId' => auth_response.authorizationResponse.litleTxnId, 'amount' => '10000'}
177
+ hash1a = auth_reversal_hash.merge(@@merchant_hash)
178
+ auth_reversal_response = LitleOnlineRequest.new.auth_reversal(hash1a)
179
+ assert_equal('336', auth_reversal_response.authReversalResponse.response)
180
+ assert_equal('Reversal Amount does not match Authorization amount', auth_reversal_response.authReversalResponse.message)
182
181
  end
183
182
 
184
183
  end
@@ -24,7 +24,7 @@ class Litle_certTest4 < Test::Unit::TestCase
24
24
  'routingNum' => '053100300'}
25
25
  }
26
26
  hash = customer_hash.merge(@@merchant_hash)
27
- echeck_response = LitleOnlineRequest.new.echeckVerification(hash)
27
+ echeck_response = LitleOnlineRequest.new.echeck_verification(hash)
28
28
  assert_equal('301', echeck_response.echeckVerificationResponse.response)
29
29
  assert_equal('Invalid Account Number', echeck_response.echeckVerificationResponse.message)
30
30
  end
@@ -46,7 +46,7 @@ class Litle_certTest4 < Test::Unit::TestCase
46
46
  'routingNum' => '053000219'}
47
47
  }
48
48
  hash = customer_hash.merge(@@merchant_hash)
49
- echeck_response = LitleOnlineRequest.new.echeckVerification(hash)
49
+ echeck_response = LitleOnlineRequest.new.echeck_verification(hash)
50
50
  assert_equal('000', echeck_response.echeckVerificationResponse.response)
51
51
  assert_equal('Approved', echeck_response.echeckVerificationResponse.message)
52
52
  end
@@ -69,7 +69,7 @@ class Litle_certTest4 < Test::Unit::TestCase
69
69
  'routingNum' => '053100300'}
70
70
  }
71
71
  hash = customer_hash.merge(@@merchant_hash)
72
- echeck_response = LitleOnlineRequest.new.echeckVerification(hash)
72
+ echeck_response = LitleOnlineRequest.new.echeck_verification(hash)
73
73
  assert_equal('950', echeck_response.echeckVerificationResponse.response)
74
74
  assert_equal('Declined - Negative Information on File', echeck_response.echeckVerificationResponse.message)
75
75
  end
@@ -92,7 +92,7 @@ class Litle_certTest4 < Test::Unit::TestCase
92
92
  'routingNum' => '063102152'}
93
93
  }
94
94
  hash = customer_hash.merge(@@merchant_hash)
95
- echeck_response = LitleOnlineRequest.new.echeckVerification(hash)
95
+ echeck_response = LitleOnlineRequest.new.echeck_verification(hash)
96
96
  assert_equal('951', echeck_response.echeckVerificationResponse.response)
97
97
  assert_equal('Absolute Decline', echeck_response.echeckVerificationResponse.message)
98
98
  end
@@ -114,7 +114,7 @@ class Litle_certTest4 < Test::Unit::TestCase
114
114
  'routingNum' => '053100300'}
115
115
  }
116
116
  hash = customer_hash.merge(@@merchant_hash)
117
- echeck_response = LitleOnlineRequest.new.echeckSale(hash)
117
+ echeck_response = LitleOnlineRequest.new.echeck_sale(hash)
118
118
 
119
119
  assert_equal('301', echeck_response.echeckSalesResponse.response)
120
120
  assert_equal('Invalid Account Number', echeck_response.echeckSalesResponse.message)
@@ -135,7 +135,7 @@ class Litle_certTest4 < Test::Unit::TestCase
135
135
  'routingNum' => '211370545'}
136
136
  }
137
137
  hash = customer_hash.merge(@@merchant_hash)
138
- echeck_response = LitleOnlineRequest.new.echeckSale(hash)
138
+ echeck_response = LitleOnlineRequest.new.echeck_sale(hash)
139
139
 
140
140
  assert_equal('000', echeck_response.echeckSalesResponse.response)
141
141
  assert_equal('Approved', echeck_response.echeckSalesResponse.message)
@@ -158,7 +158,7 @@ class Litle_certTest4 < Test::Unit::TestCase
158
158
  'routingNum' => '211370545'}
159
159
  }
160
160
  hash = customer_hash.merge(@@merchant_hash)
161
- echeck_response = LitleOnlineRequest.new.echeckSale(hash)
161
+ echeck_response = LitleOnlineRequest.new.echeck_sale(hash)
162
162
 
163
163
  assert_equal('000', echeck_response.echeckSalesResponse.response)
164
164
  assert_equal('Approved', echeck_response.echeckSalesResponse.message)
@@ -181,7 +181,7 @@ class Litle_certTest4 < Test::Unit::TestCase
181
181
  'routingNum' => '053133052'}
182
182
  }
183
183
  hash = customer_hash.merge(@@merchant_hash)
184
- echeck_response = LitleOnlineRequest.new.echeckSale(hash)
184
+ echeck_response = LitleOnlineRequest.new.echeck_sale(hash)
185
185
 
186
186
  assert_equal('900', echeck_response.echeckSalesResponse.response)
187
187
  assert_equal('Invalid Bank Routing Number', echeck_response.echeckSalesResponse.message)
@@ -203,10 +203,9 @@ class Litle_certTest4 < Test::Unit::TestCase
203
203
  'routingNum' => '053100300'}
204
204
  }
205
205
  hash = customer_hash.merge(@@merchant_hash)
206
- echeck_response = LitleOnlineRequest.new.echeckCredit(hash)
206
+ echeck_response = LitleOnlineRequest.new.echeck_credit(hash)
207
207
 
208
208
  assert_equal('301', echeck_response.echeckCreditResponse.response)
209
- # assert_equal('InValid Account Number', echeck_response.echeckCreditResponse.message)
210
209
  end
211
210
 
212
211
  def test_46
@@ -225,7 +224,7 @@ class Litle_certTest4 < Test::Unit::TestCase
225
224
  'routingNum' => '063102152'}
226
225
  }
227
226
  hash = customer_hash.merge(@@merchant_hash)
228
- echeck_response = LitleOnlineRequest.new.echeckCredit(hash)
227
+ echeck_response = LitleOnlineRequest.new.echeck_credit(hash)
229
228
 
230
229
  assert_equal('000', echeck_response.echeckCreditResponse.response)
231
230
  assert_equal('Approved', echeck_response.echeckCreditResponse.message)
@@ -247,7 +246,7 @@ class Litle_certTest4 < Test::Unit::TestCase
247
246
  'routingNum' => '211370545'}
248
247
  }
249
248
  hash = customer_hash.merge(@@merchant_hash)
250
- echeck_response = LitleOnlineRequest.new.echeckCredit(hash)
249
+ echeck_response = LitleOnlineRequest.new.echeck_credit(hash)
251
250
 
252
251
  assert_equal('000', echeck_response.echeckCreditResponse.response)
253
252
  assert_equal('Approved', echeck_response.echeckCreditResponse.message)
@@ -255,11 +254,10 @@ class Litle_certTest4 < Test::Unit::TestCase
255
254
 
256
255
  def test_48
257
256
  customer_hash = {
258
- #'orderId' => '48',
259
257
  'litleTxnId' => '430000000000000001'
260
258
  }
261
259
  hash = customer_hash.merge(@@merchant_hash)
262
- echeck_response = LitleOnlineRequest.new.echeckCredit(hash)
260
+ echeck_response = LitleOnlineRequest.new.echeck_credit(hash)
263
261
 
264
262
  assert_equal('000', echeck_response.echeckCreditResponse.response)
265
263
  assert_equal('Approved', echeck_response.echeckCreditResponse.message)
@@ -267,11 +265,10 @@ class Litle_certTest4 < Test::Unit::TestCase
267
265
 
268
266
  def test_49
269
267
  customer_hash = {
270
- #'orderId' => '49',
271
268
  'litleTxnId' => '2'
272
269
  }
273
270
  hash = customer_hash.merge(@@merchant_hash)
274
- echeck_response = LitleOnlineRequest.new.echeckCredit(hash)
271
+ echeck_response = LitleOnlineRequest.new.echeck_credit(hash)
275
272
 
276
273
  assert_equal('360', echeck_response.echeckCreditResponse.response)
277
274
  assert_equal('No transaction found with specified litleTxnId', echeck_response.echeckCreditResponse.message)
@@ -2,7 +2,6 @@ require 'lib/LitleOnline'
2
2
  require 'test/unit'
3
3
 
4
4
  class Litle_certTest5 < Test::Unit::TestCase
5
- #### test token transactions with merchantid 087902 username IMPTKN, password cert3d6Z#####
6
5
  @@merchant_hash = {'reportGroup'=>'Planets',
7
6
  'merchantId'=>'101'
8
7
  }
@@ -13,7 +12,7 @@ class Litle_certTest5 < Test::Unit::TestCase
13
12
  'accountNumber' => '4457119922390123'
14
13
  }
15
14
  hash = customer_hash.merge(@@merchant_hash)
16
- token_response = LitleOnlineRequest.new.registerTokenRequest(hash)
15
+ token_response = LitleOnlineRequest.new.register_token_request(hash)
17
16
  assert_equal('445711', token_response.registerTokenResponse.bin)
18
17
  assert_equal('VI', token_response.registerTokenResponse.type)
19
18
  assert_equal('801', token_response.registerTokenResponse.response)
@@ -27,7 +26,7 @@ class Litle_certTest5 < Test::Unit::TestCase
27
26
  'accountNumber' => '4457119999999999'
28
27
  }
29
28
  hash = customer_hash.merge(@@merchant_hash)
30
- token_response = LitleOnlineRequest.new.registerTokenRequest(hash)
29
+ token_response = LitleOnlineRequest.new.register_token_request(hash)
31
30
  assert_equal('820', token_response.registerTokenResponse.response)
32
31
  assert_equal('Credit card number was invalid', token_response.registerTokenResponse.message)
33
32
  end
@@ -38,7 +37,7 @@ class Litle_certTest5 < Test::Unit::TestCase
38
37
  'accountNumber' => '4457119922390123'
39
38
  }
40
39
  hash = customer_hash.merge(@@merchant_hash)
41
- token_response = LitleOnlineRequest.new.registerTokenRequest(hash)
40
+ token_response = LitleOnlineRequest.new.register_token_request(hash)
42
41
  assert_equal('445711', token_response.registerTokenResponse.bin)
43
42
  assert_equal('VI', token_response.registerTokenResponse.type)
44
43
  assert_equal('802', token_response.registerTokenResponse.response)
@@ -46,13 +45,13 @@ class Litle_certTest5 < Test::Unit::TestCase
46
45
  assert_equal('Account number was previously registered', token_response.registerTokenResponse.message)
47
46
  end
48
47
 
49
- def test_53 #merchant is not authorized for echeck tokens
48
+ def test_53
50
49
  customer_hash = {
51
50
  'orderId' => '53',
52
51
  'echeckForToken'=>{'accNum'=>'1099999998','routingNum'=>'114567895'}
53
52
  }
54
53
  hash = customer_hash.merge(@@merchant_hash)
55
- token_response = LitleOnlineRequest.new.registerTokenRequest(hash)
54
+ token_response = LitleOnlineRequest.new.register_token_request(hash)
56
55
  assert_equal('EC', token_response.registerTokenResponse.type)
57
56
  assert_equal('998', token_response.registerTokenResponse.eCheckAccountSuffix)
58
57
  assert_equal('801', token_response.registerTokenResponse.response)
@@ -60,13 +59,13 @@ class Litle_certTest5 < Test::Unit::TestCase
60
59
  assert_equal('111922223333000998', token_response.registerTokenResponse.litleToken)
61
60
  end
62
61
 
63
- def test_54 #merchant is not authorized for echeck tokens
62
+ def test_54
64
63
  customer_hash = {
65
64
  'orderId' => '54',
66
65
  'echeckForToken'=>{'accNum'=>'1022222102','routingNum'=>'1145_7895'}
67
66
  }
68
67
  hash = customer_hash.merge(@@merchant_hash)
69
- token_response = LitleOnlineRequest.new.registerTokenRequest(hash)
68
+ token_response = LitleOnlineRequest.new.register_token_request(hash)
70
69
  assert_equal('900', token_response.registerTokenResponse.response)
71
70
  assert_equal('Invalid bank routing number', token_response.registerTokenResponse.message)
72
71
  end
@@ -117,25 +116,7 @@ class Litle_certTest5 < Test::Unit::TestCase
117
116
  assert_equal('MC', token_response.authorizationResponse.tokenResponse.type)
118
117
  assert_equal('543510', token_response.authorizationResponse.tokenResponse.bin)
119
118
  end
120
-
121
- ## def test_58
122
- ## customer_hash = {
123
- ## 'orderId' => '58',
124
- ## 'amount' => '15000',
125
- ## 'orderSource' => 'ecommerce',
126
- ##
127
- ## 'card' => {'expDate' => '1112', 'cardValidationNum' => '987'}
128
- ## }
129
- ## hash = customer_hash.merge(@@merchant_hash)
130
- ## token_response = LitleOnlineRequest.new.authorization(hash)
131
- ## assert_equal('000', token_response.authorizationResponse.response)
132
- ## assert_equal('Approved', token_response.authorizationResponse.message)
133
- ## assert_equal('801', token_response.authorizationResponse.tokenResponse.tokenResponseCode)
134
- ## assert_equal('Account number was successfully registered', token_response.authorizationResponse.tokenResponse.tokenMessage)
135
- ## assert_equal('MC', token_response.authorizationResponse.tokenResponse.type)
136
- ## assert_equal('543510', token_response.authorizationResponse.tokenResponse.bin)
137
- ## end
138
- #
119
+
139
120
  def test_59
140
121
  customer_hash = {
141
122
  'orderId' => '59',
@@ -162,7 +143,6 @@ class Litle_certTest5 < Test::Unit::TestCase
162
143
  assert_equal('Token was invalid', token_response.authorizationResponse.message)
163
144
  end
164
145
 
165
- # test 61-64 need echecksale to support token. merchantid not authoried.
166
146
  def test_61
167
147
  customer_hash = {
168
148
  'orderId' => '61',
@@ -174,7 +154,7 @@ class Litle_certTest5 < Test::Unit::TestCase
174
154
  'echeck' => {'accType' => 'Checking', 'accNum' => '1099999003', 'routingNum' => '114567895'}
175
155
  }
176
156
  hash = customer_hash.merge(@@merchant_hash)
177
- token_response = LitleOnlineRequest.new.echeckSale(hash)
157
+ token_response = LitleOnlineRequest.new.echeck_sale(hash)
178
158
  assert_equal('801', token_response.echeckSalesResponse.tokenResponse.tokenResponseCode)
179
159
  assert_equal('Account number was successfully registered', token_response.echeckSalesResponse.tokenResponse.tokenMessage)
180
160
  assert_equal('EC', token_response.echeckSalesResponse.tokenResponse.type)
@@ -193,7 +173,7 @@ class Litle_certTest5 < Test::Unit::TestCase
193
173
  'echeck' => {'accType' => 'Checking', 'accNum' => '1099999999', 'routingNum' => '114567895'}
194
174
  }
195
175
  hash = customer_hash.merge(@@merchant_hash)
196
- token_response = LitleOnlineRequest.new.echeckSale(hash)
176
+ token_response = LitleOnlineRequest.new.echeck_sale(hash)
197
177
  assert_equal('801', token_response.echeckSalesResponse.tokenResponse.tokenResponseCode)
198
178
  assert_equal('Account number was successfully registered', token_response.echeckSalesResponse.tokenResponse.tokenMessage)
199
179
  assert_equal('EC', token_response.echeckSalesResponse.tokenResponse.type)
@@ -212,7 +192,7 @@ class Litle_certTest5 < Test::Unit::TestCase
212
192
  'echeck' => {'accType' => 'Checking', 'accNum' => '1099999999', 'routingNum' => '214567892'}
213
193
  }
214
194
  hash = customer_hash.merge(@@merchant_hash)
215
- token_response = LitleOnlineRequest.new.echeckSale(hash)
195
+ token_response = LitleOnlineRequest.new.echeck_sale(hash)
216
196
  assert_equal('801', token_response.echeckSalesResponse.tokenResponse.tokenResponseCode)
217
197
  assert_equal('Account number was successfully registered', token_response.echeckSalesResponse.tokenResponse.tokenMessage)
218
198
  assert_equal('EC', token_response.echeckSalesResponse.tokenResponse.type)
@@ -27,7 +27,7 @@ require 'test/unit'
27
27
 
28
28
  #test Authorization Transaction
29
29
  class TestAuth < Test::Unit::TestCase
30
- def test_simpleAuthwithCard
30
+ def test_simple_auth_with_card
31
31
  hash = {
32
32
  'merchantId' => '101',
33
33
  'version'=>'8.8',
@@ -44,7 +44,7 @@ class TestAuth < Test::Unit::TestCase
44
44
  assert_equal('000', response.authorizationResponse.response)
45
45
  end
46
46
 
47
- def test_simpleAuthwithpaypal
47
+ def test_simple_auth_with_paypal
48
48
  hash = {
49
49
  'merchantId' => '101',
50
50
  'version'=>'8.8',
@@ -61,7 +61,7 @@ class TestAuth < Test::Unit::TestCase
61
61
  assert_equal 'Valid Format', response.message
62
62
  end
63
63
 
64
- def test_illegalorderSource
64
+ def test_illegal_order_source
65
65
  hash = {
66
66
  'merchantId' => '101',
67
67
  'version'=>'8.8',
@@ -78,7 +78,7 @@ class TestAuth < Test::Unit::TestCase
78
78
  assert(response.message =~ /Error validating xml data against the schema/)
79
79
  end
80
80
 
81
- def test_FieldsOutOfOrder
81
+ def test_fields_out_of_order
82
82
  hash = {
83
83
  'merchantId' => '101',
84
84
  'version'=>'8.8',
@@ -96,7 +96,7 @@ class TestAuth < Test::Unit::TestCase
96
96
  assert_equal('000', response.authorizationResponse.response)
97
97
  end
98
98
 
99
- def test_InvalidField
99
+ def test_invalid_field
100
100
  hash = {
101
101
  'merchantId' => '101',
102
102
  'version'=>'8.8',
@@ -114,7 +114,7 @@ class TestAuth < Test::Unit::TestCase
114
114
  assert_equal('000', response.authorizationResponse.response)
115
115
  end
116
116
 
117
- def test_poswithoutCapabilityandentryMode
117
+ def test_pos_without_capability_and_entry_mode
118
118
  hash = {
119
119
  'merchantId' => '101',
120
120
  'version'=>'8.8',
@@ -26,7 +26,7 @@ require 'lib/LitleOnline'
26
26
  require 'test/unit'
27
27
 
28
28
  class TestAuthReversal < Test::Unit::TestCase
29
- def test_simpleAuthReversal
29
+ def test_simple_auth_reversal
30
30
  hash = {
31
31
  'merchantId' => '101',
32
32
  'version'=>'8.8',
@@ -35,11 +35,11 @@ class TestAuthReversal < Test::Unit::TestCase
35
35
  'amount'=>'106',
36
36
  'payPalNotes'=>'Notes'
37
37
  }
38
- response= LitleOnlineRequest.new.authReversal(hash)
38
+ response= LitleOnlineRequest.new.auth_reversal(hash)
39
39
  assert_equal('Valid Format', response.message)
40
40
  end
41
41
 
42
- def test_FieldsOutOfOrder
42
+ def test_fields_out_of_order
43
43
  hash = {
44
44
  'merchantId' => '101',
45
45
  'version'=>'8.8',
@@ -48,11 +48,11 @@ class TestAuthReversal < Test::Unit::TestCase
48
48
  'amount'=>'106',
49
49
  'reportGroup'=>'Planets',
50
50
  }
51
- response= LitleOnlineRequest.new.authReversal(hash)
51
+ response= LitleOnlineRequest.new.auth_reversal(hash)
52
52
  assert_equal('Valid Format', response.message)
53
53
  end
54
54
 
55
- def test_InvalidField
55
+ def test_invalid_field
56
56
  hash = {
57
57
  'merchantId' => '101',
58
58
  'version'=>'8.8',
@@ -62,7 +62,7 @@ class TestAuthReversal < Test::Unit::TestCase
62
62
  'amount'=>'106',
63
63
  'reportGroup'=>'Planets',
64
64
  }
65
- response= LitleOnlineRequest.new.authReversal(hash)
65
+ response= LitleOnlineRequest.new.auth_reversal(hash)
66
66
  assert_equal('Valid Format', response.message)
67
67
  end
68
68
  end