HornsAndHooves-flat_map 0.3.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/.ruby-version +1 -1
- data/HornsAndHooves-flat_map.gemspec +5 -5
- data/lib/flat_map/model_mapper/persistence.rb +0 -7
- data/lib/flat_map/version.rb +1 -1
- data/spec/flat_map/mapper/persistence_spec.rb +1 -1
- data/spec/flat_map/mapper/targeting_spec.rb +1 -1
- data/spec/spec_helper.rb +6 -0
- metadata +13 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 23416b70e99b971920d90bd08042a9eb6546c491
|
4
|
+
data.tar.gz: 3cbae8bc6cae945dcddf3227747c01f2828661a4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7842dba339d91147a548440e9fe725a6646349854f59c1723e3683bef6fde7a2b6c956bf550496331dcf378e4281b0264f7530355d94caef59ffcf62715feaae
|
7
|
+
data.tar.gz: 848349e424a794e646cedee5e1ac3cdfc23129bd695d61914222ff1a29fe41079f54284f1f632fabe4f866bb28f4d1e69092f83ca52222716b20f3dacdb086e9
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.2
|
@@ -5,8 +5,8 @@ require "flat_map/version"
|
|
5
5
|
Gem::Specification.new do |s|
|
6
6
|
s.name = "HornsAndHooves-flat_map"
|
7
7
|
s.version = FlatMap::VERSION
|
8
|
-
s.authors = ["HornsAndHooves", "Artem Kuzko", "Zachary Belzer", "Sergey Potapov"]
|
9
|
-
s.email = ["a.kuzko@gmail.com", "zbelzer@gmail.com", "blake131313@gmail.com"]
|
8
|
+
s.authors = ["HornsAndHooves", "Artem Kuzko", "Zachary Belzer", "Sergey Potapov", "Bruce Burdick"]
|
9
|
+
s.email = ["a.kuzko@gmail.com", "zbelzer@gmail.com", "blake131313@gmail.com", "rubygems.org@bruceburdick.com"]
|
10
10
|
s.homepage = "https://github.com/HornsAndHooves/flat_map"
|
11
11
|
s.licenses = ["LICENSE"]
|
12
12
|
s.summary = %q{Deep object graph to a plain properties mapper}
|
@@ -19,11 +19,11 @@ Gem::Specification.new do |s|
|
|
19
19
|
s.require_paths = ["lib"]
|
20
20
|
|
21
21
|
# specify any dependencies here; for example:
|
22
|
-
s.add_dependency(%q<activesupport>, ["
|
23
|
-
s.add_dependency(%q<activerecord>, ["
|
22
|
+
s.add_dependency(%q<activesupport>, ["~> 4.2"])
|
23
|
+
s.add_dependency(%q<activerecord>, ["~> 4.2"])
|
24
24
|
s.add_dependency(%q<yard>, [">= 0"])
|
25
25
|
|
26
|
-
s.add_development_dependency "rspec"
|
26
|
+
s.add_development_dependency "rspec", ['~> 3.5']
|
27
27
|
s.add_development_dependency "rspec-its"
|
28
28
|
s.add_development_dependency "rake"
|
29
29
|
end
|
@@ -55,13 +55,6 @@ module FlatMap
|
|
55
55
|
end
|
56
56
|
end
|
57
57
|
|
58
|
-
# Return a 'mapper' string as a model_name. Used by Rails FormBuilder.
|
59
|
-
#
|
60
|
-
# @return [String]
|
61
|
-
def model_name
|
62
|
-
'mapper'
|
63
|
-
end
|
64
|
-
|
65
58
|
# Delegate to the target's #to_key method.
|
66
59
|
# @return [String]
|
67
60
|
def to_key
|
data/lib/flat_map/version.rb
CHANGED
@@ -66,7 +66,7 @@ module FlatMap
|
|
66
66
|
let(:mapper){ PersistenceSpec::TargetClassMapper.new(target){} }
|
67
67
|
|
68
68
|
specify '#model_name' do
|
69
|
-
expect(mapper.model_name).to
|
69
|
+
expect(mapper.model_name).to respond_to :human
|
70
70
|
end
|
71
71
|
|
72
72
|
specify '#to_key should delegate to target' do
|
@@ -66,7 +66,7 @@ module FlatMap
|
|
66
66
|
let(:mapper){ ModelMethodsSpec::TargetClassMapper.new(target){} }
|
67
67
|
|
68
68
|
specify '#model_name' do
|
69
|
-
expect(mapper.model_name).to
|
69
|
+
expect(mapper.model_name).to respond_to :human
|
70
70
|
end
|
71
71
|
|
72
72
|
specify '#to_key should delegate to target' do
|
data/spec/spec_helper.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'bundler/setup'
|
2
|
+
|
1
3
|
require 'flat_map'
|
2
4
|
require 'ostruct'
|
3
5
|
require 'pry'
|
@@ -7,3 +9,7 @@ require 'simplecov'
|
|
7
9
|
SimpleCov.start do
|
8
10
|
add_filter '/spec/'
|
9
11
|
end
|
12
|
+
|
13
|
+
RSpec.configure do |config|
|
14
|
+
config.treat_symbols_as_metadata_keys_with_true_values = true
|
15
|
+
end
|
metadata
CHANGED
@@ -1,56 +1,45 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: HornsAndHooves-flat_map
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- HornsAndHooves
|
8
8
|
- Artem Kuzko
|
9
9
|
- Zachary Belzer
|
10
10
|
- Sergey Potapov
|
11
|
+
- Bruce Burdick
|
11
12
|
autorequire:
|
12
13
|
bindir: bin
|
13
14
|
cert_chain: []
|
14
|
-
date:
|
15
|
+
date: 2016-07-18 00:00:00.000000000 Z
|
15
16
|
dependencies:
|
16
17
|
- !ruby/object:Gem::Dependency
|
17
18
|
name: activesupport
|
18
19
|
requirement: !ruby/object:Gem::Requirement
|
19
20
|
requirements:
|
20
|
-
- - "
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: '4.0'
|
23
|
-
- - "<"
|
21
|
+
- - "~>"
|
24
22
|
- !ruby/object:Gem::Version
|
25
23
|
version: '4.2'
|
26
24
|
type: :runtime
|
27
25
|
prerelease: false
|
28
26
|
version_requirements: !ruby/object:Gem::Requirement
|
29
27
|
requirements:
|
30
|
-
- - "
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
version: '4.0'
|
33
|
-
- - "<"
|
28
|
+
- - "~>"
|
34
29
|
- !ruby/object:Gem::Version
|
35
30
|
version: '4.2'
|
36
31
|
- !ruby/object:Gem::Dependency
|
37
32
|
name: activerecord
|
38
33
|
requirement: !ruby/object:Gem::Requirement
|
39
34
|
requirements:
|
40
|
-
- - "
|
41
|
-
- !ruby/object:Gem::Version
|
42
|
-
version: '4.0'
|
43
|
-
- - "<"
|
35
|
+
- - "~>"
|
44
36
|
- !ruby/object:Gem::Version
|
45
37
|
version: '4.2'
|
46
38
|
type: :runtime
|
47
39
|
prerelease: false
|
48
40
|
version_requirements: !ruby/object:Gem::Requirement
|
49
41
|
requirements:
|
50
|
-
- - "
|
51
|
-
- !ruby/object:Gem::Version
|
52
|
-
version: '4.0'
|
53
|
-
- - "<"
|
42
|
+
- - "~>"
|
54
43
|
- !ruby/object:Gem::Version
|
55
44
|
version: '4.2'
|
56
45
|
- !ruby/object:Gem::Dependency
|
@@ -71,16 +60,16 @@ dependencies:
|
|
71
60
|
name: rspec
|
72
61
|
requirement: !ruby/object:Gem::Requirement
|
73
62
|
requirements:
|
74
|
-
- - "
|
63
|
+
- - "~>"
|
75
64
|
- !ruby/object:Gem::Version
|
76
|
-
version: '
|
65
|
+
version: '3.5'
|
77
66
|
type: :development
|
78
67
|
prerelease: false
|
79
68
|
version_requirements: !ruby/object:Gem::Requirement
|
80
69
|
requirements:
|
81
|
-
- - "
|
70
|
+
- - "~>"
|
82
71
|
- !ruby/object:Gem::Version
|
83
|
-
version: '
|
72
|
+
version: '3.5'
|
84
73
|
- !ruby/object:Gem::Dependency
|
85
74
|
name: rspec-its
|
86
75
|
requirement: !ruby/object:Gem::Requirement
|
@@ -116,6 +105,7 @@ email:
|
|
116
105
|
- a.kuzko@gmail.com
|
117
106
|
- zbelzer@gmail.com
|
118
107
|
- blake131313@gmail.com
|
108
|
+
- rubygems.org@bruceburdick.com
|
119
109
|
executables: []
|
120
110
|
extensions: []
|
121
111
|
extra_rdoc_files: []
|
@@ -203,7 +193,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
203
193
|
version: '0'
|
204
194
|
requirements: []
|
205
195
|
rubyforge_project:
|
206
|
-
rubygems_version: 2.
|
196
|
+
rubygems_version: 2.4.6
|
207
197
|
signing_key:
|
208
198
|
specification_version: 4
|
209
199
|
summary: Deep object graph to a plain properties mapper
|
@@ -231,4 +221,3 @@ test_files:
|
|
231
221
|
- spec/flat_map/mapping_spec.rb
|
232
222
|
- spec/flat_map/open_mapper_spec.rb
|
233
223
|
- spec/spec_helper.rb
|
234
|
-
has_rdoc:
|