stall-atos 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +13 -0
- data/lib/stall/atos/gateway.rb +6 -6
- data/lib/stall/atos/version.rb +1 -1
- data/stall-atos.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 49fd0d4a1497869ad8c4f4c654fa99b18e31ce29
|
4
|
+
data.tar.gz: f7bb221e69c0b36a06e476259fd27412b09254ba
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ac8aa7095ff2a27ac9361baffc085b76944b05e48b1ddeb1b0eeb3c6bb3a4075480d2b60b6563ec55effa23907da33f8b908b3a3843f56aab019b38ade54057a
|
7
|
+
data.tar.gz: 9e6c53d18f19239797055fa6989f042ad78f5bdea7bf9f50e76f170ccee458dc7cf518902bc355a4631a3876bc0f6934ecfacde4ba44085915430b228c5f169f
|
data/README.md
CHANGED
@@ -70,6 +70,19 @@ You can find the route with :
|
|
70
70
|
rake routes | grep payment/notify
|
71
71
|
```
|
72
72
|
|
73
|
+
### Faking a payment notification
|
74
|
+
|
75
|
+
From your console :
|
76
|
+
|
77
|
+
```ruby
|
78
|
+
# Fetch the cart you want to simulate a payment notification for
|
79
|
+
cart = Cart.last
|
80
|
+
# Create the fake notification request
|
81
|
+
request = Stall::Atos::FakeGatewayPaymentNotification.new(cart)
|
82
|
+
# Pass it to the PaymentNotificationService, where the simulation will take place
|
83
|
+
Stall::PaymentNotificationService.new('atos', request).call
|
84
|
+
```
|
85
|
+
|
73
86
|
## Contributing
|
74
87
|
|
75
88
|
Bug reports and pull requests are welcome on GitHub at https://github.com/stall-rails/stall-atos.
|
data/lib/stall/atos/gateway.rb
CHANGED
@@ -101,20 +101,20 @@ module Stall
|
|
101
101
|
@request = request
|
102
102
|
end
|
103
103
|
|
104
|
-
def
|
105
|
-
|
104
|
+
def valid?
|
105
|
+
response.valid?
|
106
106
|
end
|
107
107
|
|
108
108
|
def success?
|
109
109
|
response.success?
|
110
110
|
end
|
111
111
|
|
112
|
-
def
|
113
|
-
|
112
|
+
def process
|
113
|
+
valid? && success?
|
114
114
|
end
|
115
115
|
|
116
|
-
def
|
117
|
-
|
116
|
+
def rendering_options
|
117
|
+
{ nothing: true }
|
118
118
|
end
|
119
119
|
|
120
120
|
def cart
|
data/lib/stall/atos/version.rb
CHANGED
data/stall-atos.gemspec
CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
|
|
19
19
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
20
|
spec.require_paths = ['lib']
|
21
21
|
|
22
|
-
spec.add_dependency 'stall', '~> 0.
|
22
|
+
spec.add_dependency 'stall', '~> 0.3'
|
23
23
|
|
24
24
|
spec.add_development_dependency 'bundler', '~> 1.11'
|
25
25
|
spec.add_development_dependency 'rake', '~> 10.0'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: stall-atos
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- vala
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-02-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: stall
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '0.
|
19
|
+
version: '0.3'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '0.
|
26
|
+
version: '0.3'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -113,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
113
113
|
version: '0'
|
114
114
|
requirements: []
|
115
115
|
rubyforge_project:
|
116
|
-
rubygems_version: 2.
|
116
|
+
rubygems_version: 2.6.8
|
117
117
|
signing_key:
|
118
118
|
specification_version: 4
|
119
119
|
summary: Stall e-commerce CM-CIC payment gateway integration
|