polyamorous 0.5.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/polyamorous.rb +2 -2
- data/lib/polyamorous/version.rb +1 -1
- data/polyamorous.gemspec +1 -1
- data/spec/support/schema.rb +2 -3
- metadata +45 -14
data/lib/polyamorous.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require "polyamorous/version"
|
2
|
+
require 'active_record'
|
2
3
|
|
3
4
|
module Polyamorous
|
4
5
|
if defined?(::ActiveRecord::Associations::JoinDependency)
|
@@ -10,10 +11,9 @@ module Polyamorous
|
|
10
11
|
end
|
11
12
|
end
|
12
13
|
|
13
|
-
require 'active_record'
|
14
14
|
require 'polyamorous/join'
|
15
15
|
require 'polyamorous/join_association'
|
16
16
|
require 'polyamorous/join_dependency'
|
17
17
|
|
18
18
|
Polyamorous::JoinDependency.send(:include, Polyamorous::JoinDependencyExtensions)
|
19
|
-
Polyamorous::JoinAssociation.send(:include, Polyamorous::JoinAssociationExtensions)
|
19
|
+
Polyamorous::JoinAssociation.send(:include, Polyamorous::JoinAssociationExtensions)
|
data/lib/polyamorous/version.rb
CHANGED
data/polyamorous.gemspec
CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
|
|
19
19
|
|
20
20
|
s.rubyforge_project = "polyamorous"
|
21
21
|
|
22
|
-
s.add_dependency 'activerecord', '
|
22
|
+
s.add_dependency 'activerecord', '>= 3.0'
|
23
23
|
s.add_development_dependency 'rspec', '~> 2.6.0'
|
24
24
|
s.add_development_dependency 'machinist', '~> 1.0.6'
|
25
25
|
s.add_development_dependency 'faker', '~> 0.9.5'
|
data/spec/support/schema.rb
CHANGED
@@ -37,8 +37,7 @@ end
|
|
37
37
|
|
38
38
|
module Schema
|
39
39
|
def self.create
|
40
|
-
|
41
|
-
ActiveRecord::Migration.verbose = false
|
40
|
+
silence_stream(STDOUT) do
|
42
41
|
|
43
42
|
ActiveRecord::Schema.define do
|
44
43
|
create_table :people, :force => true do |t|
|
@@ -100,4 +99,4 @@ module Schema
|
|
100
99
|
Comment.make(:body => 'First post!', :article => Article.make(:title => 'Hello, world!'))
|
101
100
|
|
102
101
|
end
|
103
|
-
end
|
102
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: polyamorous
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,22 +9,27 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2013-02-14 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activerecord
|
16
|
-
requirement:
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
|
-
- -
|
19
|
+
- - ! '>='
|
20
20
|
- !ruby/object:Gem::Version
|
21
21
|
version: '3.0'
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements:
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ! '>='
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: '3.0'
|
25
30
|
- !ruby/object:Gem::Dependency
|
26
31
|
name: rspec
|
27
|
-
requirement:
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
28
33
|
none: false
|
29
34
|
requirements:
|
30
35
|
- - ~>
|
@@ -32,10 +37,15 @@ dependencies:
|
|
32
37
|
version: 2.6.0
|
33
38
|
type: :development
|
34
39
|
prerelease: false
|
35
|
-
version_requirements:
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ~>
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: 2.6.0
|
36
46
|
- !ruby/object:Gem::Dependency
|
37
47
|
name: machinist
|
38
|
-
requirement:
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
39
49
|
none: false
|
40
50
|
requirements:
|
41
51
|
- - ~>
|
@@ -43,10 +53,15 @@ dependencies:
|
|
43
53
|
version: 1.0.6
|
44
54
|
type: :development
|
45
55
|
prerelease: false
|
46
|
-
version_requirements:
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ~>
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 1.0.6
|
47
62
|
- !ruby/object:Gem::Dependency
|
48
63
|
name: faker
|
49
|
-
requirement:
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
50
65
|
none: false
|
51
66
|
requirements:
|
52
67
|
- - ~>
|
@@ -54,10 +69,15 @@ dependencies:
|
|
54
69
|
version: 0.9.5
|
55
70
|
type: :development
|
56
71
|
prerelease: false
|
57
|
-
version_requirements:
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ~>
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: 0.9.5
|
58
78
|
- !ruby/object:Gem::Dependency
|
59
79
|
name: sqlite3
|
60
|
-
requirement:
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
61
81
|
none: false
|
62
82
|
requirements:
|
63
83
|
- - ~>
|
@@ -65,7 +85,12 @@ dependencies:
|
|
65
85
|
version: 1.3.3
|
66
86
|
type: :development
|
67
87
|
prerelease: false
|
68
|
-
version_requirements:
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ~>
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: 1.3.3
|
69
94
|
description: ! "\n This is just an extraction from Ransack/Squeel. You probably
|
70
95
|
don't want to use this\n directly. It extends ActiveRecord's associations to
|
71
96
|
support polymorphic belongs_to\n associations.\n "
|
@@ -109,15 +134,21 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
109
134
|
- - ! '>='
|
110
135
|
- !ruby/object:Gem::Version
|
111
136
|
version: '0'
|
137
|
+
segments:
|
138
|
+
- 0
|
139
|
+
hash: 1064198230970801175
|
112
140
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
113
141
|
none: false
|
114
142
|
requirements:
|
115
143
|
- - ! '>='
|
116
144
|
- !ruby/object:Gem::Version
|
117
145
|
version: '0'
|
146
|
+
segments:
|
147
|
+
- 0
|
148
|
+
hash: 1064198230970801175
|
118
149
|
requirements: []
|
119
150
|
rubyforge_project: polyamorous
|
120
|
-
rubygems_version: 1.8.
|
151
|
+
rubygems_version: 1.8.24
|
121
152
|
signing_key:
|
122
153
|
specification_version: 3
|
123
154
|
summary: Loves/is loved by polymorphic belongs_to associations, Ransack, Squeel, MetaSearch...
|