beyonic 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/lib/beyonic.rb +1 -0
- data/lib/beyonic/abstract_api.rb +7 -2
- data/lib/beyonic/collection.rb +5 -0
- data/lib/beyonic/payment.rb +0 -1
- data/lib/beyonic/version.rb +1 -1
- metadata +37 -66
- data/.gitignore +0 -14
- data/.rspec +0 -2
- data/Gemfile +0 -4
- data/LICENSE.txt +0 -22
- data/Rakefile +0 -2
- data/beyonic.gemspec +0 -30
- data/spec/beyonic/payment_spec.rb +0 -223
- data/spec/beyonic/webhook_spec.rb +0 -393
- data/spec/examples/invalid_token_error.json +0 -3
- data/spec/examples/no_permissions_error.json +0 -3
- data/spec/examples/payments/create_invalid_response.json +0 -5
- data/spec/examples/payments/create_response.json +0 -28
- data/spec/examples/payments/get_response.json +0 -23
- data/spec/examples/payments/list_response.json +0 -98
- data/spec/examples/webhooks/create_invalid_response.json +0 -5
- data/spec/examples/webhooks/create_response.json +0 -8
- data/spec/examples/webhooks/get_response.json +0 -8
- data/spec/examples/webhooks/list_response.json +0 -18
- data/spec/examples/webhooks/payments/create_invalid_response.json +0 -5
- data/spec/examples/webhooks/payments/create_response.json +0 -28
- data/spec/examples/webhooks/payments/get_response.json +0 -8
- data/spec/examples/webhooks/payments/list_response.json +0 -98
- data/spec/examples/webhooks/update_invalid_response.json +0 -5
- data/spec/examples/webhooks/update_response.json +0 -8
- data/spec/spec_helper.rb +0 -33
@@ -1,98 +0,0 @@
|
|
1
|
-
[
|
2
|
-
{
|
3
|
-
"id": 23,
|
4
|
-
"organization": 2,
|
5
|
-
"amount": "0.0000",
|
6
|
-
"currency": "UGX",
|
7
|
-
"payment_type": "money",
|
8
|
-
"metadata": null,
|
9
|
-
"description": "Test Payments",
|
10
|
-
"phone_nos": [],
|
11
|
-
"state": "processed_with_errors",
|
12
|
-
"last_error": "Error with payment 21. Error: (1062, \"Duplicate entry '6-2013-08-29 14:27:43-5000.0000' for key 'account_id_2'\") Type: IntegrityError",
|
13
|
-
"rejected_reason": null,
|
14
|
-
"rejected_by": null,
|
15
|
-
"rejected_time": null,
|
16
|
-
"cancelled_reason": null,
|
17
|
-
"cancelled_by": null,
|
18
|
-
"cancelled_time": null,
|
19
|
-
"created": "2013-08-29T14:27:42Z",
|
20
|
-
"author": 2,
|
21
|
-
"modified": "2013-09-29T23:26:02Z",
|
22
|
-
"updated_by": 1,
|
23
|
-
"start_date": "2013-08-29T00:00:00Z"
|
24
|
-
},
|
25
|
-
{
|
26
|
-
"id": 24,
|
27
|
-
"organization": 2,
|
28
|
-
"amount": "0.0000",
|
29
|
-
"currency": "UGX",
|
30
|
-
"payment_type": "money",
|
31
|
-
"metadata": null,
|
32
|
-
"description": "Trying to re-create \"Track Payments\" bug",
|
33
|
-
"phone_nos": [],
|
34
|
-
"state": "processed_with_errors",
|
35
|
-
"last_error": "Error with payment 23. Error: (1062, \"Duplicate entry '6-2013-08-29 15:15:55-5000.0000' for key 'account_id_2'\") Type: IntegrityError",
|
36
|
-
"rejected_reason": null,
|
37
|
-
"rejected_by": null,
|
38
|
-
"rejected_time": null,
|
39
|
-
"cancelled_reason": null,
|
40
|
-
"cancelled_by": null,
|
41
|
-
"cancelled_time": null,
|
42
|
-
"created": "2013-08-29T15:15:54Z",
|
43
|
-
"author": 2,
|
44
|
-
"modified": "2013-09-29T23:26:02Z",
|
45
|
-
"updated_by": 1,
|
46
|
-
"start_date": "2013-08-29T00:00:00Z"
|
47
|
-
},
|
48
|
-
{
|
49
|
-
"id": 3601,
|
50
|
-
"organization": 2,
|
51
|
-
"amount": "30.0000",
|
52
|
-
"currency": "UGX",
|
53
|
-
"payment_type": "money",
|
54
|
-
"metadata": null,
|
55
|
-
"description": "Per diem payment",
|
56
|
-
"phone_nos": [
|
57
|
-
"+256772781923"
|
58
|
-
],
|
59
|
-
"state": "processed",
|
60
|
-
"last_error": null,
|
61
|
-
"rejected_reason": null,
|
62
|
-
"rejected_by": null,
|
63
|
-
"rejected_time": null,
|
64
|
-
"cancelled_reason": null,
|
65
|
-
"cancelled_by": null,
|
66
|
-
"cancelled_time": null,
|
67
|
-
"created": "2014-11-30T14:49:04Z",
|
68
|
-
"author": 2,
|
69
|
-
"modified": "2014-11-30T14:49:41Z",
|
70
|
-
"updated_by": null,
|
71
|
-
"start_date": "2014-11-30T14:49:04Z"
|
72
|
-
},
|
73
|
-
{
|
74
|
-
"id": 3602,
|
75
|
-
"organization": 2,
|
76
|
-
"amount": "100.2000",
|
77
|
-
"currency": "UGX",
|
78
|
-
"payment_type": "money",
|
79
|
-
"metadata": null,
|
80
|
-
"description": "Per diem payment",
|
81
|
-
"phone_nos": [
|
82
|
-
"+256773712831"
|
83
|
-
],
|
84
|
-
"state": "processed",
|
85
|
-
"last_error": null,
|
86
|
-
"rejected_reason": null,
|
87
|
-
"rejected_by": null,
|
88
|
-
"rejected_time": null,
|
89
|
-
"cancelled_reason": null,
|
90
|
-
"cancelled_by": null,
|
91
|
-
"cancelled_time": null,
|
92
|
-
"created": "2014-11-30T15:31:49Z",
|
93
|
-
"author": 2,
|
94
|
-
"modified": "2014-11-30T15:32:42Z",
|
95
|
-
"updated_by": null,
|
96
|
-
"start_date": "2014-11-30T15:31:49Z"
|
97
|
-
}
|
98
|
-
]
|
@@ -1,18 +0,0 @@
|
|
1
|
-
[
|
2
|
-
{
|
3
|
-
"id": 1,
|
4
|
-
"created": "2014-11-30T14:48:20Z",
|
5
|
-
"updated": "2014-11-30T14:48:20Z",
|
6
|
-
"user": 2,
|
7
|
-
"event": "payment.status.changed",
|
8
|
-
"target": "https://my.website/payments/callback"
|
9
|
-
},
|
10
|
-
{
|
11
|
-
"id": 2,
|
12
|
-
"created": "2014-11-30T19:10:31Z",
|
13
|
-
"updated": "2014-11-30T19:10:31Z",
|
14
|
-
"user": 2,
|
15
|
-
"event": "payment.status.changed",
|
16
|
-
"target": "https://my.callback.url/"
|
17
|
-
}
|
18
|
-
]
|
@@ -1,28 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"id": 3607,
|
3
|
-
"organization": 2,
|
4
|
-
"amount": "100.2",
|
5
|
-
"currency": "UGX",
|
6
|
-
"payment_type": "money",
|
7
|
-
"metadata": {
|
8
|
-
"id": "1234",
|
9
|
-
"name": "Lucy"
|
10
|
-
},
|
11
|
-
"description": "Per diem payment",
|
12
|
-
"phone_nos": [
|
13
|
-
"+256773712831"
|
14
|
-
],
|
15
|
-
"state": "new",
|
16
|
-
"last_error": null,
|
17
|
-
"rejected_reason": null,
|
18
|
-
"rejected_by": null,
|
19
|
-
"rejected_time": null,
|
20
|
-
"cancelled_reason": null,
|
21
|
-
"cancelled_by": null,
|
22
|
-
"cancelled_time": null,
|
23
|
-
"created": "2014-11-30T16:08:25.421Z",
|
24
|
-
"author": 2,
|
25
|
-
"modified": "2014-11-30T16:08:25.422Z",
|
26
|
-
"updated_by": null,
|
27
|
-
"start_date": "2014-11-30T16:08:25.422Z"
|
28
|
-
}
|
@@ -1,98 +0,0 @@
|
|
1
|
-
[
|
2
|
-
{
|
3
|
-
"id": 23,
|
4
|
-
"organization": 2,
|
5
|
-
"amount": "0.0000",
|
6
|
-
"currency": "UGX",
|
7
|
-
"payment_type": "money",
|
8
|
-
"metadata": null,
|
9
|
-
"description": "Test Payments",
|
10
|
-
"phone_nos": [],
|
11
|
-
"state": "processed_with_errors",
|
12
|
-
"last_error": "Error with payment 21. Error: (1062, \"Duplicate entry '6-2013-08-29 14:27:43-5000.0000' for key 'account_id_2'\") Type: IntegrityError",
|
13
|
-
"rejected_reason": null,
|
14
|
-
"rejected_by": null,
|
15
|
-
"rejected_time": null,
|
16
|
-
"cancelled_reason": null,
|
17
|
-
"cancelled_by": null,
|
18
|
-
"cancelled_time": null,
|
19
|
-
"created": "2013-08-29T14:27:42Z",
|
20
|
-
"author": 2,
|
21
|
-
"modified": "2013-09-29T23:26:02Z",
|
22
|
-
"updated_by": 1,
|
23
|
-
"start_date": "2013-08-29T00:00:00Z"
|
24
|
-
},
|
25
|
-
{
|
26
|
-
"id": 24,
|
27
|
-
"organization": 2,
|
28
|
-
"amount": "0.0000",
|
29
|
-
"currency": "UGX",
|
30
|
-
"payment_type": "money",
|
31
|
-
"metadata": null,
|
32
|
-
"description": "Trying to re-create \"Track Payments\" bug",
|
33
|
-
"phone_nos": [],
|
34
|
-
"state": "processed_with_errors",
|
35
|
-
"last_error": "Error with payment 23. Error: (1062, \"Duplicate entry '6-2013-08-29 15:15:55-5000.0000' for key 'account_id_2'\") Type: IntegrityError",
|
36
|
-
"rejected_reason": null,
|
37
|
-
"rejected_by": null,
|
38
|
-
"rejected_time": null,
|
39
|
-
"cancelled_reason": null,
|
40
|
-
"cancelled_by": null,
|
41
|
-
"cancelled_time": null,
|
42
|
-
"created": "2013-08-29T15:15:54Z",
|
43
|
-
"author": 2,
|
44
|
-
"modified": "2013-09-29T23:26:02Z",
|
45
|
-
"updated_by": 1,
|
46
|
-
"start_date": "2013-08-29T00:00:00Z"
|
47
|
-
},
|
48
|
-
{
|
49
|
-
"id": 3601,
|
50
|
-
"organization": 2,
|
51
|
-
"amount": "30.0000",
|
52
|
-
"currency": "UGX",
|
53
|
-
"payment_type": "money",
|
54
|
-
"metadata": null,
|
55
|
-
"description": "Per diem payment",
|
56
|
-
"phone_nos": [
|
57
|
-
"+256772781923"
|
58
|
-
],
|
59
|
-
"state": "processed",
|
60
|
-
"last_error": null,
|
61
|
-
"rejected_reason": null,
|
62
|
-
"rejected_by": null,
|
63
|
-
"rejected_time": null,
|
64
|
-
"cancelled_reason": null,
|
65
|
-
"cancelled_by": null,
|
66
|
-
"cancelled_time": null,
|
67
|
-
"created": "2014-11-30T14:49:04Z",
|
68
|
-
"author": 2,
|
69
|
-
"modified": "2014-11-30T14:49:41Z",
|
70
|
-
"updated_by": null,
|
71
|
-
"start_date": "2014-11-30T14:49:04Z"
|
72
|
-
},
|
73
|
-
{
|
74
|
-
"id": 3602,
|
75
|
-
"organization": 2,
|
76
|
-
"amount": "100.2000",
|
77
|
-
"currency": "UGX",
|
78
|
-
"payment_type": "money",
|
79
|
-
"metadata": null,
|
80
|
-
"description": "Per diem payment",
|
81
|
-
"phone_nos": [
|
82
|
-
"+256773712831"
|
83
|
-
],
|
84
|
-
"state": "processed",
|
85
|
-
"last_error": null,
|
86
|
-
"rejected_reason": null,
|
87
|
-
"rejected_by": null,
|
88
|
-
"rejected_time": null,
|
89
|
-
"cancelled_reason": null,
|
90
|
-
"cancelled_by": null,
|
91
|
-
"cancelled_time": null,
|
92
|
-
"created": "2014-11-30T15:31:49Z",
|
93
|
-
"author": 2,
|
94
|
-
"modified": "2014-11-30T15:32:42Z",
|
95
|
-
"updated_by": null,
|
96
|
-
"start_date": "2014-11-30T15:31:49Z"
|
97
|
-
}
|
98
|
-
]
|
data/spec/spec_helper.rb
DELETED
@@ -1,33 +0,0 @@
|
|
1
|
-
require 'simplecov'
|
2
|
-
SimpleCov.start do
|
3
|
-
add_filter "/spec/"
|
4
|
-
end
|
5
|
-
|
6
|
-
|
7
|
-
require 'rubygems'
|
8
|
-
require 'bundler/setup'
|
9
|
-
|
10
|
-
require 'beyonic'
|
11
|
-
require 'webmock/rspec'
|
12
|
-
require 'rspec/collection_matchers'
|
13
|
-
|
14
|
-
# This file was generated by the `rspec --init` command. Conventionally, all
|
15
|
-
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
|
16
|
-
# Require this file using `require "spec_helper"` to ensure that it is only
|
17
|
-
# loaded once.
|
18
|
-
#
|
19
|
-
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
20
|
-
RSpec.configure do |config|
|
21
|
-
config.run_all_when_everything_filtered = true
|
22
|
-
config.filter_run :focus
|
23
|
-
config.expectation_framework = :rspec
|
24
|
-
config.mock_framework = :rspec
|
25
|
-
|
26
|
-
config.raise_errors_for_deprecations!
|
27
|
-
|
28
|
-
# Run specs in random order to surface order dependencies. If you find an
|
29
|
-
# order dependency and want to debug it, you can fix the order by providing
|
30
|
-
# the seed, which is printed after each run.
|
31
|
-
# --seed 1234
|
32
|
-
config.order = 'random'
|
33
|
-
end
|