epics 1.7.2 → 1.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 16a3bb74f8943c4f82b808e830e2306d2af5bfb80e80a4985ca47760b8e6a28f
4
- data.tar.gz: 2ae911622605fb2965431fd7fb78f16e97e4bf1151fe0ec0f47c30632015a125
3
+ metadata.gz: 0a022ab9e8c8af9a64b970a4d927b53f09321b6767545bee5c584538aa4a296a
4
+ data.tar.gz: 3dd7d404d54e32fe14993ba0272e666b94f38e1238d304c916d373ea057bff75
5
5
  SHA512:
6
- metadata.gz: 3ca8b3806e14e95aeed7576b48aebe5c04c7cbfac8e524f9e89da93716735533567d8c20529934d2bb65875b9db828318639f2d5ede1592cd53f210b41e6e398
7
- data.tar.gz: 7c8f67d58425a6dc8ce16427c89960d50ecc55f4ee18880c2012655d4f271df719dca55c955ce04da3ccd8a12e4a104b30b948af38f029884947a2484d99491b
6
+ metadata.gz: d821c36ea05aa51c005dd1dc6b86cd28f8067faf746e556e87f098fecd1a1951c2e33f3ee4a2df494a0df54e168b07f3155ea60be132a4663711a39ab03f8116
7
+ data.tar.gz: b48e1f0da804c867f0ce292f2db56352745f515607ea2292bae08c689fb6124b7c025aa4463792042a0e85feda8b4a0016b612c97cbb443d0648e5f499e84967
@@ -0,0 +1,51 @@
1
+ version: v1.0
2
+ name: Test
3
+ agent:
4
+ machine:
5
+ type: e1-standard-2
6
+ os_image: ubuntu1804
7
+ blocks:
8
+ - name: Setup
9
+ task:
10
+ jobs:
11
+ - name: "Checkout"
12
+ commands:
13
+ - checkout
14
+ - ls
15
+ - rm -f .rbenv-version .ruby-version
16
+ - name: Spec versions
17
+ task:
18
+ jobs:
19
+ - name: "2.4"
20
+ commands:
21
+ - checkout
22
+ - sem-version ruby 2.4
23
+ - cache restore
24
+ - bundle install
25
+ - cache store
26
+ - bundle exec rspec
27
+ - name: "2.5"
28
+ commands:
29
+ - checkout
30
+ - sem-version ruby 2.5
31
+ - cache restore
32
+ - bundle install
33
+ - cache store
34
+ - bundle exec rspec
35
+ - name: "2.6"
36
+ commands:
37
+ - checkout
38
+ - sem-version ruby 2.6
39
+ - cache restore
40
+ - bundle install
41
+ - cache store
42
+ - bundle exec rspec
43
+ - name: "jruby-9.2.0.0"
44
+ commands:
45
+ - checkout
46
+ - sem-version ruby jruby-9.2.0.0
47
+ - cache restore
48
+ - gem install bundler
49
+ - bundle install
50
+ - cache store
51
+ - bundle exec rspec
@@ -1,3 +1,8 @@
1
+ ### 1.8.0
2
+
3
+ - [HOUSEKEEPING] updates faraday and rubyzip
4
+ - [HOUSEKEEPING] as a result: bump required ruby version to 2.4+
5
+
1
6
  ### 1.7.2
2
7
 
3
8
  - [FEATURE] adds XCT order type (thanks to @punkle64)
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- [![Build Status](https://travis-ci.org/railslove/epics.svg?branch=master)](https://travis-ci.org/railslove/epics)
1
+ [![Build Status](https://railslove.semaphoreci.com/badges/epics/branches/master.svg?style=shields)](https://railslove.semaphoreci.com/branches/c29225c5-5b7e-4a90-8ac8-22d1aa28efcf)
2
2
  [![Gem Version](https://badge.fury.io/rb/epics.svg)](http://badge.fury.io/rb/epics)
3
3
 
4
4
  # Epics
@@ -264,4 +264,4 @@ EPICS_VERIFY_SSL=false
264
264
 
265
265
  ---
266
266
 
267
- 2014-2018 - built with love by [Railslove](http://railslove.com) and released under the [GNU LESSER GENERAL PUBLIC LICENSE](https://github.com/railslove/epics/blob/master/LICENSE.txt). We have built quite a number of FinTech products. If you need support we are happy to help. Please contact us at team@railslove.com.
267
+ 2014-2019 - built with love by [Railslove](http://railslove.com) and released under the [GNU LESSER GENERAL PUBLIC LICENSE](https://github.com/railslove/epics/blob/master/LICENSE.txt). We have built quite a number of FinTech products. If you need support we are happy to help. Please contact us at team@railslove.com.
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
26
26
  spec.homepage = 'https://github.com/railslove/epics'
27
27
  spec.license = 'LGPL-3.0'
28
28
 
29
- spec.required_ruby_version = '>= 2.0'
29
+ spec.required_ruby_version = '>= 2.4'
30
30
 
31
31
  spec.files = `git ls-files -z`.split("\x0")
32
32
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
@@ -40,19 +40,14 @@ Gem::Specification.new do |spec|
40
40
  spec.post_install_message += "Please create an issue on github (railslove/epics) if anything does not work as expected. And contact team@railslove.com if you are looking for support with your integration.\n"
41
41
  spec.post_install_message += "\e[32m" + ('*' * 60) + "\n\e[0m"
42
42
 
43
- if RUBY_VERSION < '2.1'
44
- spec.add_dependency 'nokogiri', '< 1.7.0'
45
- else
46
- spec.add_dependency 'nokogiri', '>= 1.8.5'
47
- end
48
-
49
- spec.add_dependency 'faraday'
50
- spec.add_dependency 'rubyzip', '>= 1.2.1'
43
+ spec.add_dependency 'faraday', '>= 1.0.0'
44
+ spec.add_dependency 'nokogiri', '>= 1.10.7'
45
+ spec.add_dependency 'rubyzip', '2.2.0'
51
46
 
52
47
  spec.add_development_dependency 'bundler', '>= 1.6.2'
53
48
  spec.add_development_dependency 'equivalent-xml'
54
49
  spec.add_development_dependency 'pry'
55
- spec.add_development_dependency 'rake', '~> 10.0'
50
+ spec.add_development_dependency 'rake', '~> 13.0'
56
51
  spec.add_development_dependency 'rspec'
57
52
  spec.add_development_dependency 'webmock'
58
53
  end
@@ -250,8 +250,8 @@ class Epics::Client
250
250
  @connection ||= Faraday.new(headers: { 'Content-Type' => 'text/xml', user_agent: "EPICS v#{Epics::VERSION}"}, ssl: { verify: verify_ssl? }) do |faraday|
251
251
  faraday.use Epics::XMLSIG, { client: self }
252
252
  faraday.use Epics::ParseEbics, { client: self}
253
+ # faraday.use MyAdapter
253
254
  # faraday.response :logger # log requests to STDOUT
254
- faraday.adapter Faraday.default_adapter # make requests with Net::HTTP
255
255
  end
256
256
  end
257
257
 
@@ -8,9 +8,9 @@ class Epics::ParseEbics < Faraday::Middleware
8
8
 
9
9
  def call(env)
10
10
  @app.call(env).on_complete do |response|
11
- response[:body] = ::Epics::Response.new(@client, response[:body])
12
- raise Epics::Error::TechnicalError, response[:body].technical_code if response[:body].technical_error?
13
- raise Epics::Error::BusinessError, response[:body].business_code if response[:body].business_error?
11
+ response.body = ::Epics::Response.new(@client, response.body)
12
+ raise Epics::Error::TechnicalError, response.body.technical_code if response.body.technical_error?
13
+ raise Epics::Error::BusinessError, response.body.business_code if response.body.business_error?
14
14
  end
15
15
  rescue Epics::Error::TechnicalError, Epics::Error::BusinessError
16
16
  raise # re-raise as otherwise they would be swallowed by the following rescue
@@ -6,13 +6,11 @@ class Epics::XMLSIG < Faraday::Middleware
6
6
  end
7
7
 
8
8
  def call(env)
9
- @signer = Epics::Signer.new(@client, env["body"])
9
+ @signer = Epics::Signer.new(@client, env.request_body)
10
10
  @signer.digest!
11
11
  @signer.sign!
12
12
 
13
- env["body"] = @signer.doc.to_xml(save_with: Nokogiri::XML::Node::SaveOptions::AS_XML)
14
-
13
+ env.request_body = @signer.doc.to_xml(save_with: Nokogiri::XML::Node::SaveOptions::AS_XML)
15
14
  @app.call(env)
16
15
  end
17
-
18
16
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Epics
4
- VERSION = '1.7.2'
4
+ VERSION = '1.8.0'
5
5
  end
@@ -9,7 +9,7 @@ RSpec.describe Epics::ParseEbics do
9
9
  stub.post('/technical_nok') { [200, {}, File.read(File.join(File.dirname(__FILE__), '..', 'fixtures', 'xml', 'ebics_technical_nok.xml'))] }
10
10
  stub.post('/ok') { [200, {}, File.read(File.join(File.dirname(__FILE__), '..', 'fixtures', 'xml', 'hpb_response_ebics_ns.xml'))] }
11
11
  stub.post('/timeout') { raise Faraday::TimeoutError }
12
- stub.post('/no_connection') { raise Faraday::Error::ConnectionFailed, 'peer has finished all lan parties and gone home' }
12
+ stub.post('/no_connection') { raise Faraday::ConnectionFailed, 'peer has finished all lan parties and gone home' }
13
13
  end
14
14
  end
15
15
  end
metadata CHANGED
@@ -1,57 +1,57 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: epics
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.2
4
+ version: 1.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lars Brillert
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-09-23 00:00:00.000000000 Z
11
+ date: 2020-02-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: nokogiri
14
+ name: faraday
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 1.8.5
19
+ version: 1.0.0
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: 1.8.5
26
+ version: 1.0.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: faraday
28
+ name: nokogiri
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: '0'
33
+ version: 1.10.7
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '0'
40
+ version: 1.10.7
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubyzip
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ">="
45
+ - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 1.2.1
47
+ version: 2.2.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ">="
52
+ - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 1.2.1
54
+ version: 2.2.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: bundler
57
57
  requirement: !ruby/object:Gem::Requirement
@@ -100,14 +100,14 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '10.0'
103
+ version: '13.0'
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: '10.0'
110
+ version: '13.0'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: rspec
113
113
  requirement: !ruby/object:Gem::Requirement
@@ -155,7 +155,7 @@ extra_rdoc_files: []
155
155
  files:
156
156
  - ".gitignore"
157
157
  - ".rspec"
158
- - ".travis.yml"
158
+ - ".semaphore/semaphore.yml"
159
159
  - CHANGELOG.md
160
160
  - CONTRIBUTING.md
161
161
  - Gemfile
@@ -298,7 +298,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
298
298
  requirements:
299
299
  - - ">="
300
300
  - !ruby/object:Gem::Version
301
- version: '2.0'
301
+ version: '2.4'
302
302
  required_rubygems_version: !ruby/object:Gem::Requirement
303
303
  requirements:
304
304
  - - ">="
@@ -1,11 +0,0 @@
1
- language: ruby
2
- env:
3
- - JAVA_OPTS=-Djava.security.egd=file:/dev/./urandom --server -Dcext.enabled=false -Xcompile.invokedynamic=false
4
- rvm:
5
- - 2.0.0
6
- - 2.1.10
7
- - 2.2.7
8
- - 2.3.8
9
- - 2.4.5
10
- - 2.5.3
11
- - jruby-9.1.10.0