schema_reader 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +10 -0
- data/README.md +1 -0
- data/Rakefile +6 -0
- data/lib/schema_reader/version.rb +1 -1
- data/lib/schema_reader.rb +1 -1
- data/schema.rb +1 -0
- data/schema_reader.gemspec +2 -2
- data/spec/lib/schema_reader_spec.rb +4 -0
- metadata +4 -30
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dfa28583350f38f71cb357ef0eec362e82bc8041
|
4
|
+
data.tar.gz: 08e08c0ecca1d043490d8e6c0041ae6fd80b4d9a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 61f14334fc266159320d5d0c54bcc5616c1ac03c73ee6c879e305d9e1fe52e4c07ebca6e18590b51fa73fc6861f10e36c086faa71d2514d1f8ca2f93d217eea1
|
7
|
+
data.tar.gz: d192de6013b9ad4d3faa08984946fbe445de1266650e9619496810876de15d985eeabb9b80584019e2205728a69347730f6817b367d650152222930743c8e0ec
|
data/.travis.yml
ADDED
data/README.md
CHANGED
data/Rakefile
CHANGED
data/lib/schema_reader.rb
CHANGED
@@ -35,7 +35,7 @@ module SchemaReader
|
|
35
35
|
|
36
36
|
def add_associations(field_names)
|
37
37
|
association_fields = field_names.select {|field| field =~ /_id/}
|
38
|
-
field_names += association_fields.map {|field| field.to_s.
|
38
|
+
field_names += association_fields.map {|field| field.to_s.sub('_id', '').to_sym}
|
39
39
|
field_names
|
40
40
|
end
|
41
41
|
|
data/schema.rb
CHANGED
data/schema_reader.gemspec
CHANGED
@@ -22,7 +22,7 @@ Gem::Specification.new do |spec|
|
|
22
22
|
spec.add_development_dependency "bundler", "~> 1.3"
|
23
23
|
spec.add_development_dependency "rake", "~>10.1"
|
24
24
|
spec.add_development_dependency "rspec", "~>2.14"
|
25
|
-
spec.add_development_dependency "debase", "~>0.0"
|
26
|
-
spec.add_development_dependency "ruby-debug-ide", "~>0.4"
|
25
|
+
#spec.add_development_dependency "debase", "~>0.0"
|
26
|
+
#spec.add_development_dependency "ruby-debug-ide", "~>0.4"
|
27
27
|
|
28
28
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: schema_reader
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dustin Zeisler
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-01-
|
11
|
+
date: 2014-01-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -52,34 +52,6 @@ dependencies:
|
|
52
52
|
- - ~>
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '2.14'
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: debase
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
58
|
-
requirements:
|
59
|
-
- - ~>
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
version: '0.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.0'
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: ruby-debug-ide
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
72
|
-
requirements:
|
73
|
-
- - ~>
|
74
|
-
- !ruby/object:Gem::Version
|
75
|
-
version: '0.4'
|
76
|
-
type: :development
|
77
|
-
prerelease: false
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
79
|
-
requirements:
|
80
|
-
- - ~>
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: '0.4'
|
83
55
|
description: Reads Rails Database schema and creates a class from selected table with
|
84
56
|
getters and setters.
|
85
57
|
email:
|
@@ -89,6 +61,7 @@ extensions: []
|
|
89
61
|
extra_rdoc_files: []
|
90
62
|
files:
|
91
63
|
- .gitignore
|
64
|
+
- .travis.yml
|
92
65
|
- Gemfile
|
93
66
|
- LICENSE.txt
|
94
67
|
- README.md
|
@@ -126,3 +99,4 @@ summary: This was created for unit testing Rails ActiveRecord. Instead of creati
|
|
126
99
|
form the true definition.
|
127
100
|
test_files:
|
128
101
|
- spec/lib/schema_reader_spec.rb
|
102
|
+
has_rdoc:
|