ibandit 0.11.1 → 0.11.2

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
  SHA1:
3
- metadata.gz: 17bba5420a0ce689224a7d5647b49c0dbe5bd27c
4
- data.tar.gz: 9a3c8b9b9ba74c6da7ca5aed939ed94a62f019cc
3
+ metadata.gz: d300c227e1241bbe38f67903a55eaf488372d7fd
4
+ data.tar.gz: 7b0fc9cacb089d31f3241365e073fcc8f38a5d05
5
5
  SHA512:
6
- metadata.gz: 26f67a8488839d863f943296d926170d0d8e66f65301adecadadfd70f25bb181b23816c97f83369638c4c5a78f9f49565483839148753baaab50e694b27a55af
7
- data.tar.gz: e4cfd123a7e8952036c2b23d8eb95a6fe9ce199c18df856ecd0176f12a469e1162917a0995d875c85dea307a1a556e381e00c17fe13753279ee173172b78626e
6
+ metadata.gz: 35dc612464c188343d734c5db8aa65f1d7fa685eb3cbf387e166f670adbae07fcd6de36aacaf98a15a571cd06be36ca33e958516df440950773c4294681f2c89
7
+ data.tar.gz: 26f75f511ddcf6af67c4d89474c52a1312d405cb8d013b281de30b1f77ca6a6c39c85dede2ec19fe36d3f1b2bca162e5ecd7ceb89c0fecb8389ae3cd43ba6dd8
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 0.11.2 - July 4, 2016
2
+
3
+ - Handle invalid pseudo-IBANs
4
+
1
5
  ## 0.11.1 - June 6, 2016
2
6
 
3
7
  - Update BLZ data
data/lib/ibandit/iban.rb CHANGED
@@ -10,7 +10,7 @@ module Ibandit
10
10
  if argument.is_a?(String)
11
11
  input = argument.to_s.gsub(/\s+/, '').upcase
12
12
 
13
- if pseudo_iban?(input)
13
+ if pseudo_iban?(input) && !PseudoIBANSplitter.new(input).split.nil?
14
14
  local_details = PseudoIBANSplitter.new(input).split
15
15
  build_iban_from_local_details(local_details)
16
16
  else
@@ -1,3 +1,3 @@
1
1
  module Ibandit
2
- VERSION = '0.11.1'.freeze
2
+ VERSION = '0.11.2'.freeze
3
3
  end
@@ -17,6 +17,11 @@ describe Ibandit::IBAN do
17
17
  specify { expect { iban }.to raise_error(TypeError) }
18
18
  end
19
19
 
20
+ context 'with an invalid pseudo IBAN' do
21
+ let(:arg) { 'dezzzz' }
22
+ its(:iban) { is_expected.to eq('DEZZZZ') }
23
+ end
24
+
20
25
  context 'with local details' do
21
26
  let(:arg) do
22
27
  {
metadata CHANGED
@@ -1,97 +1,97 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ibandit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.1
4
+ version: 0.11.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Grey Baker
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-05 00:00:00.000000000 Z
11
+ date: 2016-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '3.3'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '3.3'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rspec-its
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '1.2'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '1.2'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rubocop
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ~>
45
+ - - "~>"
46
46
  - !ruby/object:Gem::Version
47
47
  version: 0.33.0
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - ~>
52
+ - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: 0.33.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: sax-machine
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
- - - ~>
59
+ - - "~>"
60
60
  - !ruby/object:Gem::Version
61
61
  version: '1.3'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ~>
66
+ - - "~>"
67
67
  - !ruby/object:Gem::Version
68
68
  version: '1.3'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: nokogiri
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ~>
73
+ - - "~>"
74
74
  - !ruby/object:Gem::Version
75
75
  version: '1.6'
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ~>
80
+ - - "~>"
81
81
  - !ruby/object:Gem::Version
82
82
  version: '1.6'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: i18n
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ~>
87
+ - - "~>"
88
88
  - !ruby/object:Gem::Version
89
89
  version: 0.7.0
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ~>
94
+ - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: 0.7.0
97
97
  description: Ibandit is a Ruby library for manipulating and validating IBANs. It allows
@@ -103,10 +103,10 @@ executables: []
103
103
  extensions: []
104
104
  extra_rdoc_files: []
105
105
  files:
106
- - .gitignore
107
- - .rubocop.yml
108
- - .rubocop_todo.yml
109
- - .travis.yml
106
+ - ".gitignore"
107
+ - ".rubocop.yml"
108
+ - ".rubocop_todo.yml"
109
+ - ".travis.yml"
110
110
  - CHANGELOG.md
111
111
  - Gemfile
112
112
  - LICENSE
@@ -166,17 +166,17 @@ require_paths:
166
166
  - lib
167
167
  required_ruby_version: !ruby/object:Gem::Requirement
168
168
  requirements:
169
- - - '>='
169
+ - - ">="
170
170
  - !ruby/object:Gem::Version
171
171
  version: '0'
172
172
  required_rubygems_version: !ruby/object:Gem::Requirement
173
173
  requirements:
174
- - - '>='
174
+ - - ">="
175
175
  - !ruby/object:Gem::Version
176
176
  version: '0'
177
177
  requirements: []
178
178
  rubyforge_project:
179
- rubygems_version: 2.2.2
179
+ rubygems_version: 2.5.1
180
180
  signing_key:
181
181
  specification_version: 4
182
182
  summary: Convert national banking details into IBANs, and vice-versa.