adyen_jpiqueras 2.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +14 -0
- data/.travis.yml +30 -0
- data/CHANGELOG.md +128 -0
- data/CONTRIBUTING.md +85 -0
- data/Gemfile +11 -0
- data/LICENSE +21 -0
- data/README.md +31 -0
- data/Rakefile +54 -0
- data/adyen_jpiqueras.gemspec +44 -0
- data/config.ru +5 -0
- data/lib/adyen.rb +16 -0
- data/lib/adyen/api.rb +424 -0
- data/lib/adyen/api/cacert.pem +3894 -0
- data/lib/adyen/api/payment_service.rb +374 -0
- data/lib/adyen/api/recurring_service.rb +188 -0
- data/lib/adyen/api/response.rb +61 -0
- data/lib/adyen/api/simple_soap_client.rb +134 -0
- data/lib/adyen/api/templates/payment_service.rb +159 -0
- data/lib/adyen/api/templates/recurring_service.rb +71 -0
- data/lib/adyen/api/test_helpers.rb +133 -0
- data/lib/adyen/api/xml_querier.rb +137 -0
- data/lib/adyen/base.rb +17 -0
- data/lib/adyen/configuration.rb +179 -0
- data/lib/adyen/form.rb +419 -0
- data/lib/adyen/hpp.rb +27 -0
- data/lib/adyen/hpp/request.rb +192 -0
- data/lib/adyen/hpp/response.rb +52 -0
- data/lib/adyen/hpp/signature.rb +34 -0
- data/lib/adyen/matchers.rb +92 -0
- data/lib/adyen/notification_generator.rb +30 -0
- data/lib/adyen/railtie.rb +13 -0
- data/lib/adyen/rest.rb +67 -0
- data/lib/adyen/rest/authorise_payment.rb +234 -0
- data/lib/adyen/rest/authorise_recurring_payment.rb +46 -0
- data/lib/adyen/rest/client.rb +127 -0
- data/lib/adyen/rest/errors.rb +33 -0
- data/lib/adyen/rest/modify_payment.rb +89 -0
- data/lib/adyen/rest/payout.rb +89 -0
- data/lib/adyen/rest/request.rb +104 -0
- data/lib/adyen/rest/response.rb +80 -0
- data/lib/adyen/rest/signature.rb +27 -0
- data/lib/adyen/signature.rb +76 -0
- data/lib/adyen/templates/notification_migration.rb +29 -0
- data/lib/adyen/templates/notification_model.rb +69 -0
- data/lib/adyen/util.rb +147 -0
- data/lib/adyen/version.rb +5 -0
- data/spec/api/api_spec.rb +231 -0
- data/spec/api/payment_service_spec.rb +505 -0
- data/spec/api/recurring_service_spec.rb +236 -0
- data/spec/api/response_spec.rb +59 -0
- data/spec/api/simple_soap_client_spec.rb +133 -0
- data/spec/api/spec_helper.rb +463 -0
- data/spec/api/test_helpers_spec.rb +84 -0
- data/spec/functional/api_spec.rb +117 -0
- data/spec/functional/initializer.rb.ci +3 -0
- data/spec/functional/initializer.rb.sample +3 -0
- data/spec/spec_helper.rb +8 -0
- data/test/form_test.rb +303 -0
- data/test/functional/payment_authorisation_api_test.rb +107 -0
- data/test/functional/payment_modification_api_test.rb +58 -0
- data/test/functional/payout_api_test.rb +93 -0
- data/test/helpers/capybara.rb +12 -0
- data/test/helpers/configure_adyen.rb +6 -0
- data/test/helpers/example_server.rb +136 -0
- data/test/helpers/public/adyen.encrypt.js +679 -0
- data/test/helpers/public/adyen.encrypt.min.js +14 -0
- data/test/helpers/test_cards.rb +20 -0
- data/test/helpers/views/authorized.erb +7 -0
- data/test/helpers/views/hpp.erb +20 -0
- data/test/helpers/views/index.erb +6 -0
- data/test/helpers/views/pay.erb +36 -0
- data/test/helpers/views/redirect_shopper.erb +18 -0
- data/test/hpp/signature_test.rb +37 -0
- data/test/hpp_test.rb +250 -0
- data/test/integration/hpp_integration_test.rb +52 -0
- data/test/integration/payment_using_3d_secure_integration_test.rb +41 -0
- data/test/integration/payment_with_client_side_encryption_integration_test.rb +26 -0
- data/test/rest/signature_test.rb +36 -0
- data/test/rest_list_recurring_details_response_test.rb +22 -0
- data/test/rest_request_test.rb +43 -0
- data/test/rest_response_test.rb +19 -0
- data/test/signature_test.rb +76 -0
- data/test/test_helper.rb +45 -0
- data/test/util_test.rb +78 -0
- data/yard_extensions.rb +16 -0
- metadata +308 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 8c9637788e33f4b5ea6358b481dd6b84fa21c893
|
4
|
+
data.tar.gz: 0373397b8eea85370cff403d086d87f199075a4b
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: d7c29df5296cfca388f24baf77d5bd5d9ef7445912de358b4fadbbea2aabfdd3c86f8e1755ae57e14e55fb684e7d86cfe51c91e23f13a605eeaa25a680792ae3
|
7
|
+
data.tar.gz: e50f8976df8452af922a403fec63ffbc833d7a79c9fc6ea4531930da1760966b94e1abe12c8a80f2989f722dac02470d1340703b51002cb787837449ce8a1370
|
data/.gitignore
ADDED
data/.travis.yml
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
language: ruby
|
2
|
+
cache: bundler
|
3
|
+
script: bundle exec rake
|
4
|
+
rvm:
|
5
|
+
- "2.0"
|
6
|
+
- "2.1"
|
7
|
+
- "2.2"
|
8
|
+
- "2.3.1"
|
9
|
+
- "jruby-9.0"
|
10
|
+
- "ruby-head"
|
11
|
+
- "rbx-2"
|
12
|
+
- "jruby-head"
|
13
|
+
matrix:
|
14
|
+
allow_failures:
|
15
|
+
- rvm: jruby-head
|
16
|
+
- rvm: ruby-head
|
17
|
+
- rvm: rbx-2
|
18
|
+
before_install:
|
19
|
+
- bundle --version || gem install bundler
|
20
|
+
before_script:
|
21
|
+
- cp spec/functional/initializer.rb.ci spec/functional/initializer.rb
|
22
|
+
env:
|
23
|
+
global:
|
24
|
+
- ADYEN_MERCHANT_ACCOUNT: "VanBergenORG"
|
25
|
+
- ADYEN_API_USERNAME: "ws@Company.VanBergen"
|
26
|
+
- ADYEN_API_PASSWORD: "7phtHzbfnzsp"
|
27
|
+
sudo: false
|
28
|
+
branches:
|
29
|
+
only:
|
30
|
+
- master
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,128 @@
|
|
1
|
+
# Changelog
|
2
|
+
|
3
|
+
The following changes have been made to the library over the years. Pleae add an entry to this file as part of your pull requests.
|
4
|
+
|
5
|
+
#### Unrelease changes
|
6
|
+
|
7
|
+
Nothing yet!
|
8
|
+
|
9
|
+
#### Version 2.2.0
|
10
|
+
|
11
|
+
- Add `Adyen::HPP` to integrate with Adyen's Hosted Payment Pages. `Adyen::HPP` supports the new HMAC-256 signing mechanism. `Adyen::Form` should be considered deprecated and will be removed from a future release.
|
12
|
+
|
13
|
+
#### Version 2.1.0
|
14
|
+
|
15
|
+
- Create syntax sugar for signature responses
|
16
|
+
- Various code cleanups.
|
17
|
+
|
18
|
+
#### Version 2.0.0
|
19
|
+
|
20
|
+
- Add `Adyen::REST` to intereact with Adyen's webservices. `Adyen::API` should be considered deprecated and will be removed from a future release.
|
21
|
+
- Make client-side encryption a first class citizen.
|
22
|
+
- Add integration test suite that uses a functional example app.
|
23
|
+
- Documentation updates and improvements.
|
24
|
+
- Drop support for Ruby 1.9
|
25
|
+
|
26
|
+
#### Version 1.6.0
|
27
|
+
|
28
|
+
- Make the credit card's CVC not required for authorise calls.
|
29
|
+
- Add support for instant payments: authorise & capture in one call.
|
30
|
+
- Add support for Billet payments.
|
31
|
+
- Fix functional tests in CI, and move to Minitest for unit tests.
|
32
|
+
|
33
|
+
#### Version 1.5.0
|
34
|
+
|
35
|
+
- Drop support for Ruby 1.8.
|
36
|
+
- Add support for SEPA Direct Debit payments
|
37
|
+
- Add support for payment in installments.
|
38
|
+
- Enable client-side encryption support to one click payments.
|
39
|
+
- Add `Adyen::Form.payments_method_url`.
|
40
|
+
- Parse additional data in authorisation responses.
|
41
|
+
- Add support sending for shopper details as part of `Adyen::Form`.
|
42
|
+
- Fixed some XML encoding issues on different Ruby versions.
|
43
|
+
|
44
|
+
#### Version 1.4.1
|
45
|
+
|
46
|
+
- Improve form matchers for testing
|
47
|
+
- Fix some deprecation warnings
|
48
|
+
|
49
|
+
#### Version 1.4.0
|
50
|
+
|
51
|
+
- Add support for client-side encryption
|
52
|
+
- Add support for `fraud_offset`.
|
53
|
+
|
54
|
+
#### Version 1.3.2
|
55
|
+
|
56
|
+
- Add support sending for billing details as part of `Adyen::Form`.
|
57
|
+
- Allow setting a custom domain for the HPP payment flow.
|
58
|
+
- Allow setting default parameters on a `Adyen::Form` skin.
|
59
|
+
- Fix: recurring contracts without references.
|
60
|
+
- Several improvement sin the notification handler template.
|
61
|
+
|
62
|
+
#### Version 1.3.1
|
63
|
+
|
64
|
+
- Allow sending a shipper's statement as part of the API.
|
65
|
+
|
66
|
+
#### Version 1.3.0
|
67
|
+
|
68
|
+
- Add support for ELV direct debit payments.
|
69
|
+
- Improved error handling on SOAP errors.
|
70
|
+
|
71
|
+
#### Version 1.2.0
|
72
|
+
|
73
|
+
- Implemented the `RecurringService#store_token` API call to store credit cards for recurring billing.
|
74
|
+
- Other fixes in recurring API dure to changes in Adyen backend.
|
75
|
+
- Added some new parameters to the signature string calculations.
|
76
|
+
- Add support for storing the HTTP basic authentication credentials Adyen uses for notifications in the configuration object. Note that this gem will currently never use these, but you can refer to them when building your integration, and store your configuration in one location.
|
77
|
+
|
78
|
+
#### Version 1.1.0
|
79
|
+
|
80
|
+
- Add support for different payment flows in the form-based mode.
|
81
|
+
- Fixed some encoding issues.
|
82
|
+
|
83
|
+
#### Version 1.0.0
|
84
|
+
|
85
|
+
- Complete rewrite of the SOAP client.
|
86
|
+
- Rails 3 integration for configuration and generators.
|
87
|
+
- Removed all dependencies; Nokogiri and Rails 3 are optional.
|
88
|
+
- Configuration variables are now integrated in `Adyen.configuration`.
|
89
|
+
- Better documentation and improved testsuite.
|
90
|
+
|
91
|
+
#### Version 0.3.2
|
92
|
+
|
93
|
+
- Fixed Rails 3 ActiveRecord deprecation notice.
|
94
|
+
- Implemented the `cancelOrRefund` call for the payment SOAP service as `Adyen::SOAP::PaymentService.cancel_or_refund`
|
95
|
+
|
96
|
+
Thanks to [tibastral](https://github.com/tibastral) for implementing this SOAP call.
|
97
|
+
|
98
|
+
#### Version 0.3.1
|
99
|
+
|
100
|
+
- Implemented the `authorise` call for the payment SOAP service as `Adyen::SOAP::PaymentService.authorise`
|
101
|
+
- Implemented the `disable` call for the recurring payment SOAP service as `Adyen::SOAP::RecurringService.disable`
|
102
|
+
|
103
|
+
Thanks again to [Stefan Borsje](http://github.com/sborsje) for implementing the SOAP calls.
|
104
|
+
|
105
|
+
#### Version 0.3.0
|
106
|
+
|
107
|
+
- Switched to Yard for code documentation, which is served on [rdoc.info](http://rdoc.info/projects/wvanbergen/adyen)
|
108
|
+
- Authentication now compatible with the latest *handsoap* version 1.1.4. Please update handsoap to this version.
|
109
|
+
- Implemented the `listRecurringDetails` call for the recurring payment SOAP service as `Adyen::SOAP::RecurringService.list`
|
110
|
+
|
111
|
+
Thanks to [Stefan Borsje](http://github.com/sborsje) for fixing handsoap authentication and implementing the SOAP call.
|
112
|
+
|
113
|
+
#### Version 0.2.3
|
114
|
+
|
115
|
+
- Implemented `Adyen.load_config` to load configuration values from a Hash or YAML file.
|
116
|
+
|
117
|
+
#### Version 0.2.2
|
118
|
+
|
119
|
+
- Fixed Curb HTTP backend to handle "101 Continue" responses correctly
|
120
|
+
|
121
|
+
#### Version 0.2.1
|
122
|
+
|
123
|
+
- Added `Adyen::Form.default_arguments` to store arguments that should be used in every payment form or redirect.
|
124
|
+
|
125
|
+
#### Version 0.2.0
|
126
|
+
|
127
|
+
- Switched to gemcutter.org for gem releases.
|
128
|
+
- Added support for automatically handling skins and their shared secrets by registering them using `Adyen::Form.register_skin`
|
data/CONTRIBUTING.md
ADDED
@@ -0,0 +1,85 @@
|
|
1
|
+
# Contributing
|
2
|
+
|
3
|
+
This projects welcomes outside contributions from anyone.
|
4
|
+
|
5
|
+
## Reporting issues
|
6
|
+
|
7
|
+
Please report bugs as a [Github issue](https://github.com/wvanbergen/adyen/issues/new).
|
8
|
+
|
9
|
+
- We are not associated with Adyen. Please contact Adyen youself if you are having
|
10
|
+
trouble with your integration.
|
11
|
+
- This library supports several features that are not supported by default on a new
|
12
|
+
Adyen account. You may have to contact Adyen if you are receiving a
|
13
|
+
"010 Not allowed" response.
|
14
|
+
- Feature request issues will be closed. This is a scratch your own itch project,
|
15
|
+
so implement it yourself and open a pull request to get it included.
|
16
|
+
|
17
|
+
## Pull requests
|
18
|
+
|
19
|
+
Pull requests are welcomed; this is very much a scratch your own itch project.
|
20
|
+
Fork the project, implement your stuff and issue a pull request.
|
21
|
+
|
22
|
+
Some notes:
|
23
|
+
|
24
|
+
- Try to follow the coding style of the surrounding code.
|
25
|
+
- We prefer to keep the number of dependencies of this library to 0. So we will
|
26
|
+
not accept new runtime dependencies.
|
27
|
+
- All changes should be unit tested using Minitest. (Rspec is used only for some
|
28
|
+
of the deprecated functionality)
|
29
|
+
- All changes should be documented using
|
30
|
+
[Yardoc](http://www.rubydoc.info/gems/yard/file/docs/GettingStarted.md) notation.
|
31
|
+
- All new functionality that requires interfacing with Adyen should either come with
|
32
|
+
a functional or integration test to prevent regressions.
|
33
|
+
- It is possible that something that works with your own account, does not work with
|
34
|
+
the account we are using for CI (e.g. failure with "010 Not allowed". We may have
|
35
|
+
to ask Adyem to enable the functionality on our test account. Please let me know in
|
36
|
+
a PR comment.
|
37
|
+
- `Adyen::API` and `Adyen::Form` are deprecated. Only bugfixes to these components
|
38
|
+
will be accepted. Use and improve `Adyen::REST` and `Adyen::HPP` instead, respectively.
|
39
|
+
- **DO** add amn entry to [CHANGELOG.md](./CHANGELOG.md).
|
40
|
+
- **DO NOT** update `Adyen::VERSION`. This will be done as part of the release process.
|
41
|
+
|
42
|
+
### Become contributor
|
43
|
+
|
44
|
+
If one of your pull request gets accepted, I will add you as a contributor if you wish.
|
45
|
+
Once accepted, please be mindful that this project is used in production in several apps.
|
46
|
+
So follow good engineering practices:
|
47
|
+
|
48
|
+
- No backwards incompatible changes.
|
49
|
+
- No pushing directly to master.
|
50
|
+
- Ask for code reviews on larger changes.
|
51
|
+
|
52
|
+
### Contributors
|
53
|
+
|
54
|
+
- [Willem van Bergen](https://github.com/wvanbergen)
|
55
|
+
- [Michel Barbosa](https://github.com/mbarb0sa)
|
56
|
+
- [Stefan Borsje](https://github.com/sborsje)
|
57
|
+
- [Eloy Durán](https://github.com/alloy)
|
58
|
+
- [Tobias Bielohlawek](https://github.com/rngtng)
|
59
|
+
- Dimitri Sinitsa
|
60
|
+
- Rinaldi Fonseca
|
61
|
+
- Joost Hietbrink
|
62
|
+
- Daryl Yeo
|
63
|
+
- Washington Luiz
|
64
|
+
- Lucas Húngaro
|
65
|
+
- Richard Bone
|
66
|
+
- Benjamin Waldher
|
67
|
+
- Martin Beck
|
68
|
+
- Paweł Gościcki
|
69
|
+
- Priit Hamer
|
70
|
+
- Eugene Pimenov
|
71
|
+
- Michael Grosser
|
72
|
+
- Lukasz Lazewski
|
73
|
+
- Thibaut Assus
|
74
|
+
- Vinicius Ferriani
|
75
|
+
- Timo Rößner
|
76
|
+
- [Enzo Finidori](https://github.com/tiredenzo)
|
77
|
+
|
78
|
+
## Release process
|
79
|
+
|
80
|
+
Use the following steps to release a new version of this gem.
|
81
|
+
|
82
|
+
- Run `git co master && git pull origin master`
|
83
|
+
- Update `Adyen::VERSION`
|
84
|
+
- Move CHANGELOG items from "Unreleased" section to a new section for the chosen version number.
|
85
|
+
- Run `bundle exec rake release`
|
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
Copyright (c) 2008 - 2014
|
2
|
+
Willem van Bergen, Michel Barbosa, Stefan Borsje & Eloy Duran
|
3
|
+
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
5
|
+
a copy of this software and associated documentation files (the
|
6
|
+
"Software"), to deal in the Software without restriction, including
|
7
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
8
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
9
|
+
permit persons to whom the Software is furnished to do so, subject to
|
10
|
+
the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be
|
13
|
+
included in all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
16
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
17
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
18
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
19
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
20
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
21
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
# Adyen [![Build Status](https://travis-ci.org/wvanbergen/adyen.svg?branch=master)](https://travis-ci.org/wvanbergen/adyen)
|
2
|
+
|
3
|
+
Package to simplify including Adyen payments services into a Ruby on Rails application.
|
4
|
+
|
5
|
+
Adyen integration relies on three modes of communication between Adyen, your server and your client/customer:
|
6
|
+
|
7
|
+
- Client-to-Adyen communication using Hosted Payment Pages (HPP).
|
8
|
+
- Server-to-Adyen communication using their REST webservice.
|
9
|
+
- Adyen-to-server communications using notifications.
|
10
|
+
|
11
|
+
This library aims to ease the implementation of all these modes into your Rack application. Moreover, it provides matchers, assertions and mocks to make it easier to implement an automated test suite to assert the integration is working correctly.
|
12
|
+
|
13
|
+
### Usage
|
14
|
+
|
15
|
+
- See the [project wiki](https://github.com/wvanbergen/adyen/wiki) to get started.
|
16
|
+
- Check out [the example server](https://github.com/wvanbergen/adyen/blob/master/test/helpers/example_server.rb) for an example implementation of the HPP payment flow, and an implementation of self-hosted a payment flow that uses the REST webservice. To start the example server, run `bundle exec rackup` in the root of this project.
|
17
|
+
- Complete RDoc documentation can be found on [rubydoc.info](http://www.rubydoc.info/gems/adyen).
|
18
|
+
- For more information about Adyen, see http://www.adyen.com
|
19
|
+
- For more information about integrating Adyen, see [their manuals](https://www.adyen.com/home/support/manuals.html). Of primary interest are the HPP integration manual for `Adyen::Form`, and the API integration manual for `Adyen::REST`.
|
20
|
+
|
21
|
+
The library doesn't have any dependencies, but making Nokogiri available in your environment will greatly improve the speed of any XML and HTML processing.
|
22
|
+
|
23
|
+
### About
|
24
|
+
|
25
|
+
This package is written by Michel Barbosa and Willem van Bergen for Floorplanner.com, and
|
26
|
+
made public under the MIT license (see LICENSE). It is currently maintained by Willem van
|
27
|
+
Bergen, with help from several contributors. We are not affiliated with Adyen B.V. The software
|
28
|
+
comes without warranty of any kind, so use at your own risk.
|
29
|
+
|
30
|
+
- `CHANGELOG.md` documents the changes between releases.
|
31
|
+
- Check out `CONTRIBUTING.md` if you want to help out with this project.
|
data/Rakefile
ADDED
@@ -0,0 +1,54 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
2
|
+
require "rspec/core/rake_task"
|
3
|
+
require "rake/testtask"
|
4
|
+
|
5
|
+
namespace(:test) do
|
6
|
+
Rake::TestTask.new(:all) do |t|
|
7
|
+
t.description = "Run all tests"
|
8
|
+
t.libs << "test"
|
9
|
+
t.test_files = FileList['test/**/*_test.rb']
|
10
|
+
end
|
11
|
+
|
12
|
+
Rake::TestTask.new(:unit) do |t|
|
13
|
+
t.description = "Run unit tests"
|
14
|
+
t.libs << "test"
|
15
|
+
t.test_files = FileList['test/*_test.rb']
|
16
|
+
end
|
17
|
+
|
18
|
+
Rake::TestTask.new(:functional) do |t|
|
19
|
+
t.description = "Run functional tests"
|
20
|
+
t.libs << "test"
|
21
|
+
t.test_files = FileList['test/functional/**/*_test.rb']
|
22
|
+
end
|
23
|
+
|
24
|
+
Rake::TestTask.new(:integration) do |t|
|
25
|
+
t.description = "Run integration tests"
|
26
|
+
t.libs << "test"
|
27
|
+
t.test_files = FileList['test/integration/**/*_test.rb']
|
28
|
+
end
|
29
|
+
end
|
30
|
+
|
31
|
+
desc "Run unit and functional tests"
|
32
|
+
task :test => %w{test:unit test:functional}
|
33
|
+
|
34
|
+
RSpec::Core::RakeTask.new(:spec) do |task|
|
35
|
+
task.pattern = "./spec/**/*_spec.rb"
|
36
|
+
task.rspec_opts = ['--color']
|
37
|
+
end
|
38
|
+
|
39
|
+
CACERT_PATH = 'lib/adyen/api/cacert.pem'
|
40
|
+
|
41
|
+
desc 'Update CA root certificates for the simple SOAP client'
|
42
|
+
task :update_cacert do
|
43
|
+
tmp = '/tmp/cacert.pem.new'
|
44
|
+
sh "curl -o #{tmp} http://curl.haxx.se/ca/cacert.pem"
|
45
|
+
mv CACERT_PATH, '/tmp/cacert.pem.old'
|
46
|
+
cp tmp, CACERT_PATH
|
47
|
+
end
|
48
|
+
|
49
|
+
# # Update the cacert.pem file before each release.
|
50
|
+
# task :build => :update_cacert do
|
51
|
+
# sh "git diff-index --quiet HEAD #{CACERT_PATH} || (git add #{CACERT_PATH} && git commit -m '[API] Update CA root certificates file.')"
|
52
|
+
# end
|
53
|
+
|
54
|
+
task :default => %w{test spec}
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
|
3
|
+
lib = File.expand_path('../lib', __FILE__)
|
4
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
|
+
require 'adyen/version'
|
6
|
+
|
7
|
+
Gem::Specification.new do |s|
|
8
|
+
s.name = "adyen_jpiqueras"
|
9
|
+
s.version = Adyen::VERSION
|
10
|
+
|
11
|
+
s.required_ruby_version = '>= 1.9.3'
|
12
|
+
|
13
|
+
s.summary = "Integrate Adyen payment services in your Ruby on Rails application."
|
14
|
+
s.description = <<-EOS
|
15
|
+
Package to simplify including the Adyen payments services into a Ruby on Rails application.
|
16
|
+
The package provides functionality to create payment forms, handling and storing notifications
|
17
|
+
sent by Adyen and consuming the SOAP services provided by Adyen. Moreover, it contains helper
|
18
|
+
methods, mocks and matchers to simpify writing tests/specs for your code.
|
19
|
+
Fork version with payouts implemented.
|
20
|
+
EOS
|
21
|
+
|
22
|
+
s.authors = ['Willem van Bergen', 'Michel Barbosa', 'Stefan Borsje', 'Eloy Durán', 'Jordi Piqueras']
|
23
|
+
s.email = ['willem@vanbergen.org', 'cicaboo@gmail.com', 'mail@sborsje.nl', 'eloy.de.enige@gmail.com', 'jordi.piqueras@helpling.net']
|
24
|
+
s.homepage = 'http://github.com/wvanbergen/adyen/wiki'
|
25
|
+
s.license = 'MIT'
|
26
|
+
|
27
|
+
s.add_development_dependency('rake')
|
28
|
+
s.add_development_dependency('rspec', '~> 2.14')
|
29
|
+
s.add_development_dependency('minitest', '~> 5')
|
30
|
+
s.add_development_dependency('mocha')
|
31
|
+
s.add_development_dependency('sinatra')
|
32
|
+
s.add_development_dependency('poltergeist')
|
33
|
+
|
34
|
+
s.add_development_dependency('railties', '>= 3.2', '< 5')
|
35
|
+
s.add_development_dependency('nokogiri', '>= 1.6.8')
|
36
|
+
|
37
|
+
s.requirements << 'Having Nokogiri installed will speed up XML handling when using the SOAP API.'
|
38
|
+
|
39
|
+
s.rdoc_options << '--title' << s.name << '--main' << 'README.md' << '--line-numbers' << '--inline-source'
|
40
|
+
s.extra_rdoc_files = ['README.md', 'CHANGELOG.md', 'CONTRIBUTING.md']
|
41
|
+
|
42
|
+
s.files = `git ls-files`.split($/)
|
43
|
+
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
44
|
+
end
|