sepa_clearer 0.2.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -0
- data/README.md +1 -1
- data/bin/update_data +2 -2
- data/data/deutsche_bundesbank.csv +4818 -48021
- data/data/deutsche_bundesbank.db +0 -0
- data/lib/sepa_clearer/clearer.rb +4 -0
- data/lib/sepa_clearer/deutsche_bundesbank.rb +2 -2
- data/lib/sepa_clearer/payment_provider.rb +8 -0
- data/lib/sepa_clearer/version.rb +1 -1
- data/spec/clearer_spec.rb +2 -2
- data/spec/payment_provider_spec.rb +1 -1
- metadata +3 -4
data/data/deutsche_bundesbank.db
CHANGED
Binary file
|
data/lib/sepa_clearer/clearer.rb
CHANGED
@@ -12,8 +12,8 @@ module SepaClearer
|
|
12
12
|
def data(file = nil)
|
13
13
|
@data ||= begin
|
14
14
|
[].tap do |data|
|
15
|
-
CSV.foreach(file || default_data_file, { headers: true, col_sep: ';', header_converters: :symbol }) do |row|
|
16
|
-
data.push PaymentProvider.new(
|
15
|
+
CSV.foreach(file || default_data_file, { headers: true, col_sep: ';', header_converters: :symbol, encoding: "iso-8859-1:UTF-8" }) do |row|
|
16
|
+
data.push PaymentProvider.new(parse_raw_data(row))
|
17
17
|
end
|
18
18
|
end
|
19
19
|
end
|
data/lib/sepa_clearer/version.rb
CHANGED
data/spec/clearer_spec.rb
CHANGED
@@ -9,7 +9,7 @@ describe SepaClearer::Clearer do
|
|
9
9
|
|
10
10
|
describe '#find_by_bic' do
|
11
11
|
it 'returns the provider with the given BIC' do
|
12
|
-
expect(subject.find_by_bic('
|
12
|
+
expect(subject.find_by_bic('AABAFI22')).to be_kind_of(SepaClearer::PaymentProvider)
|
13
13
|
end
|
14
14
|
|
15
15
|
it 'returns nil if no object matches the BIC' do
|
@@ -23,7 +23,7 @@ describe SepaClearer::Clearer do
|
|
23
23
|
end
|
24
24
|
|
25
25
|
it 'returns an initialize object' do
|
26
|
-
expect(subject.find_by_bic('
|
26
|
+
expect(subject.find_by_bic('AABAFI22').name).to eq('BANK OF ALAND PLC')
|
27
27
|
end
|
28
28
|
end
|
29
29
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sepa_clearer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Maximilian Schulz
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-12-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sqlite3
|
@@ -114,7 +114,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
114
114
|
version: '0'
|
115
115
|
requirements: []
|
116
116
|
rubyforge_project:
|
117
|
-
rubygems_version: 2.
|
117
|
+
rubygems_version: 2.5.1
|
118
118
|
signing_key:
|
119
119
|
specification_version: 4
|
120
120
|
summary: List of all available SEPA clearers and their supported features
|
@@ -123,4 +123,3 @@ test_files:
|
|
123
123
|
- spec/deutsche_bundesbank_spec.rb
|
124
124
|
- spec/payment_provider_spec.rb
|
125
125
|
- spec/spec_helper.rb
|
126
|
-
has_rdoc:
|