openpay 1.0.7 → 2.0.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.
- checksums.yaml +5 -5
- data/.gitignore +1 -0
- data/.travis.yml +4 -1
- data/Gemfile +2 -2
- data/README.md +25 -25
- data/Rakefile +2 -1
- data/lib/openpay.rb +3 -0
- data/lib/openpay/open_pay_resource.rb +40 -9
- data/lib/openpay/points.rb +10 -0
- data/lib/openpay/tokens.rb +7 -0
- data/lib/openpay/utils/search_params.rb +4 -1
- data/lib/openpay/webhooks.rb +9 -0
- data/lib/version.rb +1 -1
- data/openpay.gemspec +6 -6
- data/test/Factories.rb +30 -16
- data/test/spec/bankaccounts_spec.rb +44 -17
- data/test/spec/cards_spec.rb +52 -39
- data/test/spec/charges_spec.rb +48 -71
- data/test/spec/customers_spec.rb +15 -13
- data/test/spec/exceptions_spec.rb +4 -20
- data/test/spec/fees_spec.rb +24 -18
- data/test/spec/openpayresource_spec.rb +4 -2
- data/test/spec/payouts_spec.rb +41 -44
- data/test/spec/plans_spec.rb +16 -10
- data/test/spec/points_spec.rb +26 -0
- data/test/spec/requesttimeout_spec.rb +2 -0
- data/test/spec/subscriptions_spec.rb +39 -36
- data/test/spec/transfers_spec.rb +37 -31
- data/test/spec/utils/search_params_spec.rb +1 -1
- data/test/spec_helper.rb +10 -2
- metadata +41 -49
@@ -28,7 +28,7 @@ describe OpenpayUtils do
|
|
28
28
|
search_params.limit = limit
|
29
29
|
amount = 100
|
30
30
|
search_params.amount_lte = amount
|
31
|
-
expect(search_params.to_s).to eq("?creation
|
31
|
+
expect(search_params.to_s).to eq("?creation%5Bgte%5D=2013-11-01&limit=2&amount%5Blte%5D=100")
|
32
32
|
end
|
33
33
|
end
|
34
34
|
end
|
data/test/spec_helper.rb
CHANGED
@@ -3,14 +3,22 @@ $: << 'lib'
|
|
3
3
|
$: << 'lib/openpay'
|
4
4
|
|
5
5
|
require 'openpay'
|
6
|
-
require '
|
7
|
-
|
6
|
+
require 'factory_bot'
|
7
|
+
#uncomment below to test on travis-ci
|
8
|
+
# FactoryBot.find_definitions
|
9
|
+
require 'Factories'
|
8
10
|
require 'rspec'
|
9
11
|
require 'json_spec'
|
10
12
|
|
11
13
|
RSpec.configure do |config|
|
14
|
+
config.include FactoryBot::Syntax::Methods
|
15
|
+
|
16
|
+
#uncomment below to test on local
|
17
|
+
#config.before(:suite) {FactoryBot.reload}
|
18
|
+
|
12
19
|
config.expect_with :rspec do |c|
|
13
20
|
c.syntax = :expect
|
14
21
|
config.include JsonSpec::Helpers
|
15
22
|
end
|
23
|
+
|
16
24
|
end
|
metadata
CHANGED
@@ -1,117 +1,105 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openpay
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
+
- Openpay
|
7
8
|
- ronnie_bermejo
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date:
|
12
|
+
date: 2021-03-01 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: rest-client
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
16
17
|
requirements:
|
17
|
-
- - ~>
|
18
|
+
- - "~>"
|
18
19
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
20
|
+
version: '2.0'
|
20
21
|
type: :runtime
|
21
22
|
prerelease: false
|
22
23
|
version_requirements: !ruby/object:Gem::Requirement
|
23
24
|
requirements:
|
24
|
-
- - ~>
|
25
|
+
- - "~>"
|
25
26
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
27
|
+
version: '2.0'
|
27
28
|
- !ruby/object:Gem::Dependency
|
28
29
|
name: json
|
29
30
|
requirement: !ruby/object:Gem::Requirement
|
30
31
|
requirements:
|
31
|
-
- -
|
32
|
+
- - ">="
|
32
33
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
34
|
+
version: '1.8'
|
34
35
|
type: :runtime
|
35
36
|
prerelease: false
|
36
37
|
version_requirements: !ruby/object:Gem::Requirement
|
37
38
|
requirements:
|
38
|
-
- -
|
39
|
+
- - ">="
|
39
40
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
41
|
+
version: '1.8'
|
41
42
|
- !ruby/object:Gem::Dependency
|
42
43
|
name: bundler
|
43
44
|
requirement: !ruby/object:Gem::Requirement
|
44
45
|
requirements:
|
45
|
-
- - ~>
|
46
|
+
- - "~>"
|
46
47
|
- !ruby/object:Gem::Version
|
47
48
|
version: '1.3'
|
48
49
|
type: :development
|
49
50
|
prerelease: false
|
50
51
|
version_requirements: !ruby/object:Gem::Requirement
|
51
52
|
requirements:
|
52
|
-
- - ~>
|
53
|
+
- - "~>"
|
53
54
|
- !ruby/object:Gem::Version
|
54
55
|
version: '1.3'
|
55
56
|
- !ruby/object:Gem::Dependency
|
56
57
|
name: rake
|
57
58
|
requirement: !ruby/object:Gem::Requirement
|
58
59
|
requirements:
|
59
|
-
- -
|
60
|
+
- - ">="
|
60
61
|
- !ruby/object:Gem::Version
|
61
62
|
version: '0'
|
62
63
|
type: :development
|
63
64
|
prerelease: false
|
64
65
|
version_requirements: !ruby/object:Gem::Requirement
|
65
66
|
requirements:
|
66
|
-
- -
|
67
|
+
- - ">="
|
67
68
|
- !ruby/object:Gem::Version
|
68
69
|
version: '0'
|
69
70
|
- !ruby/object:Gem::Dependency
|
70
71
|
name: json_spec
|
71
72
|
requirement: !ruby/object:Gem::Requirement
|
72
73
|
requirements:
|
73
|
-
- -
|
74
|
+
- - ">="
|
74
75
|
- !ruby/object:Gem::Version
|
75
76
|
version: '0'
|
76
77
|
type: :development
|
77
78
|
prerelease: false
|
78
79
|
version_requirements: !ruby/object:Gem::Requirement
|
79
80
|
requirements:
|
80
|
-
- -
|
81
|
+
- - ">="
|
81
82
|
- !ruby/object:Gem::Version
|
82
83
|
version: '0'
|
83
|
-
description: ruby client for Openpay API services (version
|
84
|
+
description: ruby client for Openpay API services (version 2.0.1)
|
84
85
|
email:
|
85
|
-
-
|
86
|
+
- hola@openpay.mx
|
86
87
|
executables: []
|
87
88
|
extensions: []
|
88
89
|
extra_rdoc_files: []
|
89
90
|
files:
|
90
|
-
- .gitignore
|
91
|
-
- .idea/.name
|
92
|
-
- .idea/.rakeTasks
|
93
|
-
- .idea/OpenPay.iml
|
94
|
-
- .idea/dictionaries/ronnie.xml
|
95
|
-
- .idea/encodings.xml
|
96
|
-
- .idea/misc.xml
|
97
|
-
- .idea/modules.xml
|
98
|
-
- .idea/
|
99
|
-
- .idea/
|
100
|
-
- .idea/
|
101
|
-
- .
|
102
|
-
- .idea/runConfigurations/Run_spec__exceptions_spec___OpenPay.xml
|
103
|
-
- .idea/runConfigurations/Run_spec__fees_spec___OpenPay.xml
|
104
|
-
- .idea/runConfigurations/Run_spec__payouts_spec___OpenPay.xml
|
105
|
-
- .idea/runConfigurations/Run_spec__plans_spec___OpenPay.xml
|
106
|
-
- .idea/runConfigurations/Run_spec__subscriptions_spec___OpenPay.xml
|
107
|
-
- .idea/runConfigurations/Run_spec__transfers_spec___OpenPay.xml
|
108
|
-
- .idea/runConfigurations/all_specs.xml
|
109
|
-
- .idea/runConfigurations/install_open_pay.xml
|
110
|
-
- .idea/runConfigurations/scrapbook.xml
|
111
|
-
- .idea/scopes/scope_settings.xml
|
112
|
-
- .idea/vcs.xml
|
113
|
-
- .idea/workspace.xml
|
114
|
-
- .travis.yml
|
91
|
+
- ".gitignore"
|
92
|
+
- ".idea/.name"
|
93
|
+
- ".idea/.rakeTasks"
|
94
|
+
- ".idea/OpenPay.iml"
|
95
|
+
- ".idea/dictionaries/ronnie.xml"
|
96
|
+
- ".idea/encodings.xml"
|
97
|
+
- ".idea/misc.xml"
|
98
|
+
- ".idea/modules.xml"
|
99
|
+
- ".idea/scopes/scope_settings.xml"
|
100
|
+
- ".idea/vcs.xml"
|
101
|
+
- ".idea/workspace.xml"
|
102
|
+
- ".travis.yml"
|
115
103
|
- Gemfile
|
116
104
|
- LICENSE.txt
|
117
105
|
- README.md
|
@@ -131,9 +119,12 @@ files:
|
|
131
119
|
- lib/openpay/openpay_api.rb
|
132
120
|
- lib/openpay/payouts.rb
|
133
121
|
- lib/openpay/plans.rb
|
122
|
+
- lib/openpay/points.rb
|
134
123
|
- lib/openpay/subscriptions.rb
|
124
|
+
- lib/openpay/tokens.rb
|
135
125
|
- lib/openpay/transfers.rb
|
136
126
|
- lib/openpay/utils/search_params.rb
|
127
|
+
- lib/openpay/webhooks.rb
|
137
128
|
- lib/version.rb
|
138
129
|
- openpay.gemspec
|
139
130
|
- test/Factories.rb
|
@@ -146,6 +137,7 @@ files:
|
|
146
137
|
- test/spec/openpayresource_spec.rb
|
147
138
|
- test/spec/payouts_spec.rb
|
148
139
|
- test/spec/plans_spec.rb
|
140
|
+
- test/spec/points_spec.rb
|
149
141
|
- test/spec/requesttimeout_spec.rb
|
150
142
|
- test/spec/subscriptions_spec.rb
|
151
143
|
- test/spec/transfers_spec.rb
|
@@ -153,7 +145,7 @@ files:
|
|
153
145
|
- test/spec_helper.rb
|
154
146
|
homepage: http://openpay.mx/
|
155
147
|
licenses:
|
156
|
-
- Apache
|
148
|
+
- Apache-2.0
|
157
149
|
metadata: {}
|
158
150
|
post_install_message: Thanks for installing openpay. Enjoy !
|
159
151
|
rdoc_options: []
|
@@ -161,20 +153,19 @@ require_paths:
|
|
161
153
|
- lib
|
162
154
|
- lib/openpay
|
163
155
|
- openpay
|
164
|
-
- .
|
156
|
+
- "."
|
165
157
|
required_ruby_version: !ruby/object:Gem::Requirement
|
166
158
|
requirements:
|
167
|
-
- -
|
159
|
+
- - ">="
|
168
160
|
- !ruby/object:Gem::Version
|
169
161
|
version: '0'
|
170
162
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
171
163
|
requirements:
|
172
|
-
- -
|
164
|
+
- - ">="
|
173
165
|
- !ruby/object:Gem::Version
|
174
166
|
version: '0'
|
175
167
|
requirements: []
|
176
|
-
|
177
|
-
rubygems_version: 2.0.6
|
168
|
+
rubygems_version: 3.0.3
|
178
169
|
signing_key:
|
179
170
|
specification_version: 4
|
180
171
|
summary: ruby api for openpay resources
|
@@ -189,6 +180,7 @@ test_files:
|
|
189
180
|
- test/spec/openpayresource_spec.rb
|
190
181
|
- test/spec/payouts_spec.rb
|
191
182
|
- test/spec/plans_spec.rb
|
183
|
+
- test/spec/points_spec.rb
|
192
184
|
- test/spec/requesttimeout_spec.rb
|
193
185
|
- test/spec/subscriptions_spec.rb
|
194
186
|
- test/spec/transfers_spec.rb
|