pagarme 1.9.2 → 1.9.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -4,108 +4,108 @@ require 'shoulda'
4
4
 
5
5
  def test_transaction(params = {})
6
6
  return PagarMe::Transaction.new({
7
- :card_number => "4901720080344448",
8
- :card_holder_name => "Jose da Silva",
9
- :card_expiration_month => "10",
10
- :card_expiration_year => "15",
11
- :card_cvv => "314",
12
- :amount => 1000
7
+ :card_number => "4901720080344448",
8
+ :card_holder_name => "Jose da Silva",
9
+ :card_expiration_month => "10",
10
+ :card_expiration_year => "15",
11
+ :card_cvv => "314",
12
+ :amount => 1000
13
13
  }.merge(params))
14
14
  end
15
15
 
16
16
  def test_subscription_without_plan(params = {})
17
17
  return PagarMe::Subscription.new({
18
- :payment_method => 'credit_card',
19
- :card_number => "4901720080344448",
20
- :card_holder_name => "Jose da Silva",
21
- :card_expiration_month => "10",
22
- :card_expiration_year => "15",
23
- :card_cvv => "314",
24
- :postback_url => "http://test.com/postback",
25
- :customer => {
26
- :email => 'customer@pagar.me'
27
- }
18
+ :payment_method => 'credit_card',
19
+ :card_number => "4901720080344448",
20
+ :card_holder_name => "Jose da Silva",
21
+ :card_expiration_month => "10",
22
+ :card_expiration_year => "15",
23
+ :card_cvv => "314",
24
+ :postback_url => "http://test.com/postback",
25
+ :customer => {
26
+ :email => 'customer@pagar.me'
27
+ }
28
28
  }.merge(params))
29
29
  end
30
30
 
31
31
  def test_plan(params = {})
32
32
  return PagarMe::Plan.new({
33
- :name => "Plano gold",
34
- :trial_days => 5,
35
- :days => 30,
36
- :amount => 3000,
33
+ :name => "Plano gold",
34
+ :trial_days => 5,
35
+ :days => 30,
36
+ :amount => 3000,
37
37
  }.merge(params))
38
38
  end
39
39
 
40
40
 
41
41
  def test_subscription(params = {})
42
42
  return PagarMe::Subscription.new({
43
- :payment_method => 'credit_card',
44
- :card_number => "4901720080344448",
45
- :card_holder_name => "Jose da Silva",
46
- :card_expiration_month => "10",
47
- :card_expiration_year => "15",
48
- :card_cvv => "314",
49
- :postback_url => "http://test.com/postback",
50
- :customer => {
51
- email: 'customer@pagar.me'
52
- }
43
+ :payment_method => 'credit_card',
44
+ :card_number => "4901720080344448",
45
+ :card_holder_name => "Jose da Silva",
46
+ :card_expiration_month => "10",
47
+ :card_expiration_year => "15",
48
+ :card_cvv => "314",
49
+ :postback_url => "http://test.com/postback",
50
+ :customer => {
51
+ email: 'customer@pagar.me'
52
+ }
53
53
  }.merge(params))
54
54
  end
55
55
 
56
56
  def test_transaction_with_customer(params = {})
57
57
  return PagarMe::Transaction.new({
58
- :amount => 1000,
59
- :card_number => '4901720080344448',
60
- :card_holder_name => "Jose da Silva",
61
- :card_expiration_month => 11,
62
- :card_expiration_year => "14",
63
- :card_cvv => 356,
64
- :customer => {
65
- :name => "Jose da Silva",
66
- :document_number => "36433809847",
67
- :email => "henrique@pagar.me",
68
- :address => {
69
- :street => 'Av. Brigadeiro Faria Lima',
70
- :neighborhood => 'Itaim bibi',
71
- :zipcode => '01452000',
72
- :street_number => 2941,
73
- },
74
- :phone => {
75
- :ddd => 12,
76
- :number => '981433533',
77
- },
78
- :sex => 'M',
79
- :born_at => '1970-10-11'
80
- }
58
+ :amount => 1000,
59
+ :card_number => '4901720080344448',
60
+ :card_holder_name => "Jose da Silva",
61
+ :card_expiration_month => 11,
62
+ :card_expiration_year => "14",
63
+ :card_cvv => 356,
64
+ :customer => {
65
+ :name => "Jose da Silva",
66
+ :document_number => "36433809847",
67
+ :email => "henrique@pagar.me",
68
+ :address => {
69
+ :street => 'Av. Brigadeiro Faria Lima',
70
+ :neighborhood => 'Itaim bibi',
71
+ :zipcode => '01452000',
72
+ :street_number => 2941,
73
+ },
74
+ :phone => {
75
+ :ddd => 12,
76
+ :number => '981433533',
77
+ },
78
+ :sex => 'M',
79
+ :born_at => '1970-10-11'
80
+ }
81
81
  }.merge(params))
82
82
  end
83
83
 
84
84
  def test_subscription_with_customer(params = {})
85
85
  return PagarMe::Subscription.new({
86
- :amount => 1000,
87
- :card_number => '4901720080344448',
88
- :card_holder_name => "Jose da silva",
89
- :card_expiration_month => 11,
90
- :card_expiration_year => 14,
91
- :card_cvv => 356,
92
- :customer => {
93
- :name => "Jose da Silva",
94
- :document_number => "36433809847",
95
- :email => "henrique@pagar.me",
96
- :address => {
97
- :street => 'Av. Brigadeiro Faria Lima',
98
- :neighborhood => 'Itaim bibi',
99
- :zipcode => '01452000',
100
- :street_number => 1000,
101
- } ,
102
- :phone => {
103
- :ddd => 12,
104
- :number => '981444444',
105
- } ,
106
- :sex => 'M',
107
- :born_at => '1970-10-11'
108
- }
86
+ :amount => 1000,
87
+ :card_number => '4901720080344448',
88
+ :card_holder_name => "Jose da silva",
89
+ :card_expiration_month => 11,
90
+ :card_expiration_year => 14,
91
+ :card_cvv => 356,
92
+ :customer => {
93
+ :name => "Jose da Silva",
94
+ :document_number => "36433809847",
95
+ :email => "henrique@pagar.me",
96
+ :address => {
97
+ :street => 'Av. Brigadeiro Faria Lima',
98
+ :neighborhood => 'Itaim bibi',
99
+ :zipcode => '01452000',
100
+ :street_number => 1000,
101
+ } ,
102
+ :phone => {
103
+ :ddd => 12,
104
+ :number => '981444444',
105
+ } ,
106
+ :sex => 'M',
107
+ :born_at => '1970-10-11'
108
+ }
109
109
  }.merge(params))
110
110
  end
111
111
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pagarme
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.2
4
+ version: 1.9.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pedro Franceschi
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-05-07 00:00:00.000000000 Z
12
+ date: 2014-08-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler