normalizy 1.2.0 → 1.3.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 +6 -1
- data/lib/generators/normalizy/install_generator.rb +1 -1
- data/lib/normalizy/version.rb +1 -1
- data/spec/normalizy/filters/number_spec.rb +2 -0
- data/spec/support/db/schema.rb +0 -1
- metadata +31 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8300817453468b0e7ff154ffeb0e0f9baf0684564fa7f49f844d83737276a994
|
4
|
+
data.tar.gz: 00d889cf50054c3706c1a3b4d12e986fad0329778343030376952b0c6d415180
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 96273b202baef19288ebb5f247260dcaea1f0c14a379bf70cb730ece0135398c988cd608e77a4ebb186f07f4597ee6cf8bd4157fe75e1a0144b6a0cad4f7544e
|
7
|
+
data.tar.gz: d88f9a79b46f80faa874bb391d98eece3f98fbb28fc7396730360cc049fe4e6124d38b04a366745ed45404b14495a1d78a6b2e29350f26de869c875614a511cc
|
data/CHANGELOG.md
CHANGED
data/lib/normalizy/version.rb
CHANGED
@@ -14,6 +14,7 @@ RSpec.describe Normalizy::Filters::Number do
|
|
14
14
|
it { expect(subject.call(nil)).to eq nil }
|
15
15
|
it { expect(subject.call('nil')).to eq nil }
|
16
16
|
it { expect(subject.call('')).to eq nil }
|
17
|
+
it { expect(subject.call('1 2 3')).to eq '123' }
|
17
18
|
end
|
18
19
|
|
19
20
|
context 'with :cast' do
|
@@ -27,5 +28,6 @@ RSpec.describe Normalizy::Filters::Number do
|
|
27
28
|
it { expect(subject.call(nil, cast: :to_i)).to eq nil }
|
28
29
|
it { expect(subject.call('nil', cast: :to_i)).to eq nil }
|
29
30
|
it { expect(subject.call('', cast: :to_i)).to eq nil }
|
31
|
+
it { expect(subject.call('1 2 3', cast: :to_i)).to eq 123 }
|
30
32
|
end
|
31
33
|
end
|
data/spec/support/db/schema.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: normalizy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Washington Botelho
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-08-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -17,9 +17,6 @@ dependencies:
|
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '4.1'
|
20
|
-
- - "<"
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: '6'
|
23
20
|
type: :runtime
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -27,9 +24,6 @@ dependencies:
|
|
27
24
|
- - ">="
|
28
25
|
- !ruby/object:Gem::Version
|
29
26
|
version: '4.1'
|
30
|
-
- - "<"
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: '6'
|
33
27
|
- !ruby/object:Gem::Dependency
|
34
28
|
name: pry-byebug
|
35
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -58,6 +52,34 @@ dependencies:
|
|
58
52
|
- - ">="
|
59
53
|
- !ruby/object:Gem::Version
|
60
54
|
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rubocop-performance
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rubocop-rails
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
61
83
|
- !ruby/object:Gem::Dependency
|
62
84
|
name: rubocop-rspec
|
63
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -170,8 +192,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
170
192
|
- !ruby/object:Gem::Version
|
171
193
|
version: '0'
|
172
194
|
requirements: []
|
173
|
-
|
174
|
-
rubygems_version: 2.7.7
|
195
|
+
rubygems_version: 3.0.3
|
175
196
|
signing_key:
|
176
197
|
specification_version: 4
|
177
198
|
summary: Attribute normalizer for ActiveRecord.
|