phony 2.15.23 → 2.15.24

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: ded6a4714a2bd5195e8385f4187f889d0c3aadd6
4
- data.tar.gz: 52e3cdffc4522a172347903046803fa18b9eebd2
3
+ metadata.gz: 572fba1b7b682ed46781b375884b054de7de6fab
4
+ data.tar.gz: f6138f9c796e1f00cb45cd3a605a98df02d63bbf
5
5
  SHA512:
6
- metadata.gz: e917455c4e6e3c8ee65764f9eb58eb7ca8661d1955a11b1b5926376ee2a09c5f5a86b8f5f39dc42c653ad8deed8033ac9bc8aa49d6865159cdb6d0ace8e0bd87
7
- data.tar.gz: 98d26dd34032919adf066350c8c08273188eb2667208377173f42194fee53e21fcba71bf1897d7f30daccec224bc4f7d0e6e9d07d4f01a8784c38c48da26c4a6
6
+ metadata.gz: 89645f983f0f31f5f596464a349844d1882f47a43d161c949ee0276d480df3c6d524f1bb397a0c0ed53b351d733c7ab1fc242f3b6228c88ccf00820befbec167
7
+ data.tar.gz: a1ee066aea215520461e2534093f6cb0787de4678f4902fe933bda8938bcc3b5614cfa8712456aab56bc24755b18108b1f57e34cd2166ff110bbd6bb7969d946
@@ -96,7 +96,7 @@ special_numbers_4 = %w{ 3003 4004 4020 }
96
96
 
97
97
  Phony.define do
98
98
  country '55',
99
- match(/^(11|12|13|14|15|16|17|18|19|21|22|24|27|28|31|32|33|34|35|37|38|71|73|74|75|77|79|81|82|83|84|85|86|87|88|89|91|92|93|94|95|96|97|98|99)9\d{8}$/) >> split(5,4) |
99
+ match(/^(11|12|13|14|15|16|17|18|19|21|22|24|27|28|31|32|33|34|35|37|38|61|62|63|64|65|66|67|68|69|71|73|74|75|77|79|81|82|83|84|85|86|87|88|89|91|92|93|94|95|96|97|98|99)9\d{8}$/) >> split(5,4) |
100
100
  match(ndcs) >> split(4,4) |
101
101
  one_of(special_numbers_3_4) >> split(3,4) |
102
102
  one_of(special_numbers_4) >> split(4) |
@@ -130,8 +130,16 @@ describe 'country descriptions' do
130
130
  it_splits '5571991311234', ['55', '71', '99131', '1234'] # Salvador's 9th digit
131
131
  it_splits '5579991311234', ['55', '79', '99131', '1234'] # Sergipe's 9th digit
132
132
 
133
- context "special states with 9 in mobile" do
134
- %w{ 11 12 13 14 15 16 17 18 19 21 22 24 27 28 31 32 33 34 35 37 38 71 73 74 75 77 79 81 82 83 84 85 86 87 88 89 91 92 93 94 95 96 97 98 99}.each do |state_code|
133
+ context 'special states with 9 in mobile' do
134
+ %w{
135
+ 11 12 13 14 15 16 17 18 19
136
+ 21 22 24 27 28
137
+ 31 32 33 34 35 37 38
138
+ 61 62 63 64 65 66 67 68 69
139
+ 71 73 74 75 77 79
140
+ 81 82 83 84 85 86 87 88 89
141
+ 91 92 93 94 95 96 97 98 99
142
+ }.each do |state_code|
135
143
  it_splits "55#{state_code}993051123", ['55', state_code, '99305', '1123']
136
144
  end
137
145
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phony
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.15.23
4
+ version: 2.15.24
5
5
  platform: ruby
6
6
  authors:
7
7
  - Florian Hanke
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-31 00:00:00.000000000 Z
11
+ date: 2016-06-01 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: 'Fast international phone number (E164 standard) normalizing, splitting
14
14
  and formatting. Lots of formatting options: International (+.., 00..), national