acts-as-messageable 0.4.3 → 0.4.4
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +1 -1
- data/README.md +93 -21
- data/VERSION +1 -1
- data/acts-as-messageable.gemspec +7 -5
- data/lib/acts-as-messageable/message.rb +19 -13
- data/lib/acts-as-messageable/model.rb +13 -5
- data/spec/acts-as-messageable_spec.rb +31 -11
- data/spec/inheritance_spec.rb +23 -0
- data/spec/spec_helper.rb +5 -3
- data/spec/support/send_message.rb +3 -0
- data/spec/support/user.rb +2 -0
- metadata +20 -18
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -11,10 +11,15 @@ Usage
|
|
11
11
|
|
12
12
|
To use it, add it to your Gemfile:
|
13
13
|
|
14
|
+
**Rails 3**
|
14
15
|
```ruby
|
15
16
|
gem 'acts-as-messageable'
|
16
17
|
```
|
17
18
|
|
19
|
+
**Rails 2**
|
20
|
+
Use this [fork](http://github.com/openfirmware/acts-as-messageable)
|
21
|
+
Thanks for [@openfirmware](http://github.com/openfirmware)
|
22
|
+
|
18
23
|
Post instalation
|
19
24
|
================
|
20
25
|
|
@@ -61,15 +66,14 @@ Send message
|
|
61
66
|
@bob.send_message(@alice, "Re: Message topic", "Hi alice!")
|
62
67
|
```
|
63
68
|
|
64
|
-
With hash
|
65
|
-
=========
|
69
|
+
## With hash
|
66
70
|
|
67
71
|
```ruby
|
68
72
|
@alice.send_message(@bob, { :body => "Hash body", :topic => "Hash topic" })
|
69
73
|
```
|
70
74
|
|
71
|
-
Custom required
|
72
|
-
|
75
|
+
Custom required (validation)
|
76
|
+
============================
|
73
77
|
|
74
78
|
In User model
|
75
79
|
|
@@ -77,18 +81,21 @@ In User model
|
|
77
81
|
class User < ActiveRecord::Base
|
78
82
|
acts_as_messageable :required => :body
|
79
83
|
end
|
84
|
+
```
|
80
85
|
|
86
|
+
## Normal
|
87
|
+
|
88
|
+
```ruby
|
81
89
|
@alice.send_message(@bob, { :body => "Hash body" })
|
82
90
|
```
|
83
91
|
|
84
|
-
|
92
|
+
## With hash
|
85
93
|
|
86
94
|
```ruby
|
87
95
|
@alice.send_message(@bob, "body")
|
88
96
|
```
|
89
97
|
|
90
|
-
Required sequence
|
91
|
-
=================
|
98
|
+
## Required sequence
|
92
99
|
|
93
100
|
```ruby
|
94
101
|
class User < ActiveRecord::Base
|
@@ -98,61 +105,120 @@ end
|
|
98
105
|
@alice.send_message(@bob, "body", "topic")
|
99
106
|
```
|
100
107
|
|
108
|
+
## First topic
|
109
|
+
|
110
|
+
```ruby
|
111
|
+
class User < ActiveRecord::Base
|
112
|
+
acts_as_messageable :required => [:topic, :body]
|
113
|
+
end
|
114
|
+
|
115
|
+
@alice.send_message(@bob, "topic", "body")
|
116
|
+
```
|
117
|
+
|
101
118
|
Conversation
|
102
119
|
============
|
103
120
|
|
121
|
+
```ruby
|
122
|
+
@message = @alice.send_message(@bob, "Hello bob!", "How are you?")
|
123
|
+
@message.reply("Re: Hello bob!", "I'm fine")
|
124
|
+
```
|
125
|
+
|
126
|
+
**Or in old style**
|
127
|
+
|
104
128
|
```ruby
|
105
129
|
@message = @alice.send_message(@bob, "Hello bob!", "How are you?")
|
106
130
|
@reply_message = @bob.reply_to(@message, "Re: Hello bob!", "I'm fine!")
|
107
|
-
|
131
|
+
```
|
132
|
+
|
133
|
+
## Get conversiation
|
108
134
|
|
109
|
-
|
135
|
+
```ruby
|
136
|
+
@message.conversation #=> [@message, @reply_message]
|
110
137
|
@reply_message.conversation #=> [@message, @reply_message]
|
111
138
|
```
|
112
139
|
|
113
140
|
Search
|
114
|
-
|
141
|
+
======
|
142
|
+
|
143
|
+
### Inbox
|
144
|
+
```ruby
|
145
|
+
@alice.received_messages
|
146
|
+
```
|
147
|
+
|
148
|
+
### Outbox
|
149
|
+
```ruby
|
150
|
+
@alice.sent_messages
|
151
|
+
```
|
152
|
+
### Inbox + Outbox. All messages connected with __@alice__
|
153
|
+
```ruby
|
154
|
+
@alice.messages
|
155
|
+
```
|
115
156
|
|
157
|
+
### Trash
|
116
158
|
```ruby
|
117
|
-
@alice.
|
118
|
-
|
119
|
-
@alice.sent_messages # @alice outbox
|
159
|
+
@alice.deleted_messages
|
160
|
+
```
|
120
161
|
|
121
|
-
|
162
|
+
## Filters
|
163
|
+
==========
|
122
164
|
|
165
|
+
```ruby
|
123
166
|
@alice.messages.are_from(@bob) # all message form @bob
|
124
167
|
@alice.messages.are_to(@bob) # all message to @bob
|
125
168
|
@alice.messages.with_id(@id_of_message) # message with id id_of_message
|
126
169
|
@alice.messages.readed # all readed @alice messages
|
127
170
|
@alice.messages.unread # all unreaded @alice messages
|
128
|
-
|
129
|
-
@alice.received_messages.are_from(@bob) # all messages from bob (inbox)
|
130
|
-
@alice.sent_messages.are_to(@bob) # all messages do bob (outbox)
|
131
171
|
```
|
132
172
|
|
133
|
-
|
173
|
+
|
174
|
+
**You can use multiple filters at the same time**
|
134
175
|
|
135
176
|
```ruby
|
136
177
|
@alice.messages.are_from(@bob).are_to(@alice).readed # all message from @bob to @alice and readed
|
137
178
|
@alice.deleted_messages.are_from(@bob) # all deleted messages from @bob
|
138
179
|
```
|
139
180
|
|
181
|
+
Read messages
|
182
|
+
=============
|
183
|
+
|
184
|
+
### Read message
|
185
|
+
|
186
|
+
```ruby
|
187
|
+
@message.open # open message
|
188
|
+
@message.read
|
189
|
+
@message.mark_as_read
|
190
|
+
```
|
191
|
+
|
192
|
+
### Unread message
|
193
|
+
|
194
|
+
```ruby
|
195
|
+
@message.close # unread message
|
196
|
+
@message.mark_as_unread
|
197
|
+
```
|
198
|
+
|
199
|
+
|
140
200
|
Delete message
|
141
201
|
==============
|
142
202
|
|
203
|
+
**__We must know who delete message. That why we use *.process* method to save context__**
|
204
|
+
|
143
205
|
```ruby
|
144
206
|
@message = @alice.send_message(@bob, "Topic", "Body")
|
145
207
|
|
146
208
|
@alice.messages.process do |message|
|
147
|
-
|
209
|
+
message.delete # @alice delete message
|
148
210
|
end
|
149
211
|
```
|
150
212
|
|
151
|
-
Now we can find message in trash
|
213
|
+
Now we can find message in **trash**
|
152
214
|
|
153
215
|
```ruby
|
154
216
|
@alice.deleted_messages #=> [@message]
|
217
|
+
```
|
155
218
|
|
219
|
+
We can delete the message **permanently**
|
220
|
+
|
221
|
+
```ruby
|
156
222
|
@alice.deleted_messages.process do |message|
|
157
223
|
message.delete
|
158
224
|
end
|
@@ -160,6 +226,12 @@ end
|
|
160
226
|
@alice.delete_message #=> []
|
161
227
|
```
|
162
228
|
|
163
|
-
Message
|
229
|
+
Message has been deleted **permanently**
|
230
|
+
|
231
|
+
## Delete message without context
|
232
|
+
|
233
|
+
```ruby
|
234
|
+
@alice.delete_message(@message) # @alice delete @message
|
235
|
+
```
|
164
236
|
|
165
237
|
Copyright © 2011 Piotr Niełacny (http://ruby-blog.pl), released under the MIT license
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.4.
|
1
|
+
0.4.4
|
data/acts-as-messageable.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "acts-as-messageable"
|
8
|
-
s.version = "0.4.
|
8
|
+
s.version = "0.4.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Piotr Nielacny"]
|
12
|
-
s.date = "
|
12
|
+
s.date = "2012-01-04"
|
13
13
|
s.email = "piotr.nielacny@gmail.com"
|
14
14
|
s.extra_rdoc_files = [
|
15
15
|
"README.md"
|
@@ -35,8 +35,10 @@ Gem::Specification.new do |s|
|
|
35
35
|
"spec/acts-as-messageable_spec.rb",
|
36
36
|
"spec/custom-class_spec.rb",
|
37
37
|
"spec/custom-required_spec.rb",
|
38
|
+
"spec/inheritance_spec.rb",
|
38
39
|
"spec/spec_helper.rb",
|
39
40
|
"spec/support/admin.rb",
|
41
|
+
"spec/support/send_message.rb",
|
40
42
|
"spec/support/user.rb"
|
41
43
|
]
|
42
44
|
s.homepage = "http://github.com/LTe/acts-as-messageable"
|
@@ -52,7 +54,7 @@ Gem::Specification.new do |s|
|
|
52
54
|
s.add_runtime_dependency(%q<activesupport>, [">= 3.0.0"])
|
53
55
|
s.add_runtime_dependency(%q<ancestry>, ["~> 1.2.4"])
|
54
56
|
s.add_runtime_dependency(%q<railties>, [">= 3.0.0"])
|
55
|
-
s.add_development_dependency(%q<rspec>, ["~> 2.
|
57
|
+
s.add_development_dependency(%q<rspec>, ["~> 2.7.0"])
|
56
58
|
s.add_development_dependency(%q<jeweler>, ["~> 1.6.0"])
|
57
59
|
s.add_development_dependency(%q<sqlite3-ruby>, [">= 0"])
|
58
60
|
else
|
@@ -60,7 +62,7 @@ Gem::Specification.new do |s|
|
|
60
62
|
s.add_dependency(%q<activesupport>, [">= 3.0.0"])
|
61
63
|
s.add_dependency(%q<ancestry>, ["~> 1.2.4"])
|
62
64
|
s.add_dependency(%q<railties>, [">= 3.0.0"])
|
63
|
-
s.add_dependency(%q<rspec>, ["~> 2.
|
65
|
+
s.add_dependency(%q<rspec>, ["~> 2.7.0"])
|
64
66
|
s.add_dependency(%q<jeweler>, ["~> 1.6.0"])
|
65
67
|
s.add_dependency(%q<sqlite3-ruby>, [">= 0"])
|
66
68
|
end
|
@@ -69,7 +71,7 @@ Gem::Specification.new do |s|
|
|
69
71
|
s.add_dependency(%q<activesupport>, [">= 3.0.0"])
|
70
72
|
s.add_dependency(%q<ancestry>, ["~> 1.2.4"])
|
71
73
|
s.add_dependency(%q<railties>, [">= 3.0.0"])
|
72
|
-
s.add_dependency(%q<rspec>, ["~> 2.
|
74
|
+
s.add_dependency(%q<rspec>, ["~> 2.7.0"])
|
73
75
|
s.add_dependency(%q<jeweler>, ["~> 1.6.0"])
|
74
76
|
s.add_dependency(%q<sqlite3-ruby>, [">= 0"])
|
75
77
|
end
|
@@ -21,15 +21,15 @@ module ActsAsMessageable
|
|
21
21
|
:created_at,
|
22
22
|
:updated_at
|
23
23
|
|
24
|
-
attr_accessor
|
25
|
-
cattr_accessor
|
24
|
+
attr_accessor :removed
|
25
|
+
cattr_accessor :required
|
26
26
|
|
27
27
|
|
28
28
|
# Sample documentation for scope
|
29
|
-
default_scope order(
|
30
|
-
scope :are_from, lambda { |*args| where(
|
31
|
-
scope :are_to, lambda { |*args| where(
|
32
|
-
scope :with_id, lambda { |*args| where(
|
29
|
+
default_scope order("created_at desc")
|
30
|
+
scope :are_from, lambda { |*args| where(:sent_messageable_id => args.first, :sent_messageable_type => args.first.class.name) }
|
31
|
+
scope :are_to, lambda { |*args| where(:received_messageable_id => args.first, :received_messageable_type => args.first.class.name) }
|
32
|
+
scope :with_id, lambda { |*args| where(:id => args.first) }
|
33
33
|
|
34
34
|
scope :connected_with, lambda { |*args| where("(sent_messageable_type = :sent_type and
|
35
35
|
sent_messageable_id = :sent_id and
|
@@ -37,19 +37,18 @@ module ActsAsMessageable
|
|
37
37
|
(received_messageable_type = :received_type and
|
38
38
|
received_messageable_id = :received_id and
|
39
39
|
recipient_delete = :r_delete and recipient_permanent_delete = :r_perm_delete)",
|
40
|
-
:sent_type => args.first.class.
|
40
|
+
:sent_type => args.first.class.resolve_active_record_ancestor.to_s,
|
41
41
|
:sent_id => args.first.id,
|
42
|
-
:received_type => args.first.class.
|
42
|
+
:received_type => args.first.class.resolve_active_record_ancestor.to_s,
|
43
43
|
:received_id => args.first.id,
|
44
44
|
:r_delete => args.last,
|
45
45
|
:s_delete => args.last,
|
46
46
|
:r_perm_delete => false,
|
47
47
|
:s_perm_delete => false)
|
48
48
|
}
|
49
|
-
scope :readed, lambda { where(
|
50
|
-
scope :unread, lambda { where(
|
51
|
-
scope :deleted, lambda { where(
|
52
|
-
:r_delete => true, :s_delete => true)}
|
49
|
+
scope :readed, lambda { where(:opened => true) }
|
50
|
+
scope :unread, lambda { where(:opened => false) }
|
51
|
+
scope :deleted, lambda { where(:recipient_delete => true, :sender_delete => true) }
|
53
52
|
|
54
53
|
def open?
|
55
54
|
self.opened?
|
@@ -79,6 +78,10 @@ module ActsAsMessageable
|
|
79
78
|
received_messageable
|
80
79
|
end
|
81
80
|
|
81
|
+
def participant?(user)
|
82
|
+
(to == user) || (from == user)
|
83
|
+
end
|
84
|
+
|
82
85
|
def conversation
|
83
86
|
root.subtree
|
84
87
|
end
|
@@ -86,6 +89,9 @@ module ActsAsMessageable
|
|
86
89
|
def delete
|
87
90
|
self.removed = true
|
88
91
|
end
|
89
|
-
|
92
|
+
|
93
|
+
def reply(*args)
|
94
|
+
to.reply_to(self, *args)
|
95
|
+
end
|
90
96
|
end
|
91
97
|
end
|
@@ -35,6 +35,10 @@ module ActsAsMessageable
|
|
35
35
|
include ActsAsMessageable::Model::InstanceMethods
|
36
36
|
end
|
37
37
|
|
38
|
+
def resolve_active_record_ancestor
|
39
|
+
self.reflect_on_association(:received_messages_relation).active_record
|
40
|
+
end
|
41
|
+
|
38
42
|
end
|
39
43
|
|
40
44
|
module InstanceMethods
|
@@ -82,7 +86,7 @@ module ActsAsMessageable
|
|
82
86
|
message_attributes = args.first
|
83
87
|
end
|
84
88
|
|
85
|
-
message = self.class.messages_class_name.create
|
89
|
+
message = self.class.messages_class_name.create message_attributes
|
86
90
|
|
87
91
|
self.sent_messages_relation << message
|
88
92
|
to.received_messages_relation << message
|
@@ -91,11 +95,15 @@ module ActsAsMessageable
|
|
91
95
|
end
|
92
96
|
|
93
97
|
def reply_to(message, *args)
|
94
|
-
|
95
|
-
|
96
|
-
|
98
|
+
current_user = self
|
99
|
+
|
100
|
+
if message.participant?(current_user)
|
101
|
+
reply_message = send_message(message.from, *args)
|
102
|
+
reply_message.parent = message
|
103
|
+
reply_message.save
|
97
104
|
|
98
|
-
|
105
|
+
reply_message
|
106
|
+
end
|
99
107
|
end
|
100
108
|
|
101
109
|
def delete_message(message)
|
@@ -4,10 +4,6 @@ class User < ActiveRecord::Base
|
|
4
4
|
acts_as_messageable
|
5
5
|
end
|
6
6
|
|
7
|
-
def send_message(from=@bob, to=@alice, topic="Topic", body="Body")
|
8
|
-
from.send_message(to, topic, body)
|
9
|
-
end
|
10
|
-
|
11
7
|
describe "ActsAsMessageable" do
|
12
8
|
|
13
9
|
before(:all) do
|
@@ -15,8 +11,8 @@ describe "ActsAsMessageable" do
|
|
15
11
|
end
|
16
12
|
|
17
13
|
describe "prepare for specs" do
|
18
|
-
it "should be
|
19
|
-
User.count.should ==
|
14
|
+
it "should be 4 users in database" do
|
15
|
+
User.count.should == 4
|
20
16
|
end
|
21
17
|
end
|
22
18
|
|
@@ -47,6 +43,30 @@ describe "ActsAsMessageable" do
|
|
47
43
|
@alice.messages.readed.count.should == 1
|
48
44
|
end
|
49
45
|
end
|
46
|
+
|
47
|
+
describe "reply to messages" do
|
48
|
+
it "pat should not be able to reply to a message from bob to alice" do
|
49
|
+
@message = send_message
|
50
|
+
@reply_message = @pat.reply_to(@message, "Re: Topic", "Body")
|
51
|
+
@reply_message.should be_nil
|
52
|
+
end
|
53
|
+
|
54
|
+
it "alice should be able to reply to a message from bob to alice" do
|
55
|
+
@message = send_message
|
56
|
+
@reply_message = @alice.reply_to(@message, "Re: Topic", "Body")
|
57
|
+
@reply_message.should_not be_nil
|
58
|
+
@bob.messages.are_from(@alice).count.should == 1
|
59
|
+
@alice.sent_messages.are_to(@bob).count.should == 1
|
60
|
+
end
|
61
|
+
|
62
|
+
it "alice should be able to reply to a message using the message object" do
|
63
|
+
@message = send_message
|
64
|
+
@reply_message = @message.reply("Re: Topic", "Body")
|
65
|
+
@reply_message.should_not be_nil
|
66
|
+
@bob.messages.are_from(@alice).count.should == 1
|
67
|
+
@alice.sent_messages.are_to(@bob).count.should == 1
|
68
|
+
end
|
69
|
+
end
|
50
70
|
|
51
71
|
describe "delete messages" do
|
52
72
|
it "bob should have one deleted message from alice" do
|
@@ -119,8 +139,8 @@ describe "ActsAsMessageable" do
|
|
119
139
|
@reply_message = @alice.reply_to(@message, "Re: Topic", "Body")
|
120
140
|
|
121
141
|
@reply_message.conversation.size.should == 2
|
122
|
-
@reply_message.conversation.
|
123
|
-
@reply_message.conversation.
|
142
|
+
@reply_message.conversation.last.topic.should == "Topic"
|
143
|
+
@reply_message.conversation.first.topic.should == "Re: Topic"
|
124
144
|
end
|
125
145
|
|
126
146
|
it "bob send message to alice, alice answer, and bob answer for alice answer" do
|
@@ -132,8 +152,8 @@ describe "ActsAsMessageable" do
|
|
132
152
|
m.conversation.size.should == 3
|
133
153
|
end
|
134
154
|
|
135
|
-
@message.conversation.
|
136
|
-
@reply_reply_message.conversation.
|
155
|
+
@message.conversation.first.should == @reply_reply_message
|
156
|
+
@reply_reply_message.conversation.first.should == @reply_reply_message
|
137
157
|
end
|
138
158
|
end
|
139
159
|
|
@@ -148,7 +168,7 @@ describe "ActsAsMessageable" do
|
|
148
168
|
it "messages should return in right order :created_at" do
|
149
169
|
@message = send_message
|
150
170
|
@message = send_message(@bob, @alice, "Example", "Example Body")
|
151
|
-
@alice.messages.
|
171
|
+
@alice.messages.last.body.should == "Body"
|
152
172
|
end
|
153
173
|
|
154
174
|
it "received_messages should return ActiveRecord::Relation" do
|
@@ -0,0 +1,23 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
|
+
|
3
|
+
describe "inheritance models" do
|
4
|
+
it "men send message to alice" do
|
5
|
+
send_message(@men, @alice)
|
6
|
+
@men.sent_messages.size.should be_equal(1)
|
7
|
+
@alice.received_messages.size.should be_equal(1)
|
8
|
+
end
|
9
|
+
|
10
|
+
it "messages method should receive all messages connected with user" do
|
11
|
+
send_message(@men, @alice)
|
12
|
+
@men.messages.size.should be_equal(1)
|
13
|
+
end
|
14
|
+
|
15
|
+
it "men send message and receive from alice" do
|
16
|
+
send_message(@men, @alice)
|
17
|
+
send_message(@alice, @men)
|
18
|
+
|
19
|
+
@men.messages.size.should be_equal(2)
|
20
|
+
@men.sent_messages.size.should be_equal(1)
|
21
|
+
@men.received_messages.size.should be_equal(1)
|
22
|
+
end
|
23
|
+
end
|
data/spec/spec_helper.rb
CHANGED
@@ -12,9 +12,11 @@ RSpec.configure do |config|
|
|
12
12
|
ActiveRecord::Base.establish_connection(:adapter => "sqlite3", :database => ":memory:")
|
13
13
|
create_database
|
14
14
|
|
15
|
-
@alice = User.create
|
16
|
-
@bob = User.create
|
17
|
-
@
|
15
|
+
@alice = User.create :email => "alice@example.com"
|
16
|
+
@bob = User.create :email => "bob@example.com"
|
17
|
+
@pat = User.create :email => "pat@example.com"
|
18
|
+
@admin = Admin.create :email => "admin@example.com"
|
19
|
+
@men = Men.create :email => "men@example.com"
|
18
20
|
end
|
19
21
|
|
20
22
|
config.after(:all) do
|
data/spec/support/user.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: acts-as-messageable
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.4
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,11 +9,11 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2012-01-04 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activerecord
|
16
|
-
requirement: &
|
16
|
+
requirement: &8607820 !ruby/object:Gem::Requirement
|
17
17
|
none: false
|
18
18
|
requirements:
|
19
19
|
- - ! '>='
|
@@ -21,10 +21,10 @@ dependencies:
|
|
21
21
|
version: 3.0.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
version_requirements: *
|
24
|
+
version_requirements: *8607820
|
25
25
|
- !ruby/object:Gem::Dependency
|
26
26
|
name: activesupport
|
27
|
-
requirement: &
|
27
|
+
requirement: &8606800 !ruby/object:Gem::Requirement
|
28
28
|
none: false
|
29
29
|
requirements:
|
30
30
|
- - ! '>='
|
@@ -32,10 +32,10 @@ dependencies:
|
|
32
32
|
version: 3.0.0
|
33
33
|
type: :runtime
|
34
34
|
prerelease: false
|
35
|
-
version_requirements: *
|
35
|
+
version_requirements: *8606800
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: ancestry
|
38
|
-
requirement: &
|
38
|
+
requirement: &8605940 !ruby/object:Gem::Requirement
|
39
39
|
none: false
|
40
40
|
requirements:
|
41
41
|
- - ~>
|
@@ -43,10 +43,10 @@ dependencies:
|
|
43
43
|
version: 1.2.4
|
44
44
|
type: :runtime
|
45
45
|
prerelease: false
|
46
|
-
version_requirements: *
|
46
|
+
version_requirements: *8605940
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: railties
|
49
|
-
requirement: &
|
49
|
+
requirement: &8604920 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ! '>='
|
@@ -54,21 +54,21 @@ dependencies:
|
|
54
54
|
version: 3.0.0
|
55
55
|
type: :runtime
|
56
56
|
prerelease: false
|
57
|
-
version_requirements: *
|
57
|
+
version_requirements: *8604920
|
58
58
|
- !ruby/object:Gem::Dependency
|
59
59
|
name: rspec
|
60
|
-
requirement: &
|
60
|
+
requirement: &8604220 !ruby/object:Gem::Requirement
|
61
61
|
none: false
|
62
62
|
requirements:
|
63
63
|
- - ~>
|
64
64
|
- !ruby/object:Gem::Version
|
65
|
-
version: 2.
|
65
|
+
version: 2.7.0
|
66
66
|
type: :development
|
67
67
|
prerelease: false
|
68
|
-
version_requirements: *
|
68
|
+
version_requirements: *8604220
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: jeweler
|
71
|
-
requirement: &
|
71
|
+
requirement: &8619760 !ruby/object:Gem::Requirement
|
72
72
|
none: false
|
73
73
|
requirements:
|
74
74
|
- - ~>
|
@@ -76,10 +76,10 @@ dependencies:
|
|
76
76
|
version: 1.6.0
|
77
77
|
type: :development
|
78
78
|
prerelease: false
|
79
|
-
version_requirements: *
|
79
|
+
version_requirements: *8619760
|
80
80
|
- !ruby/object:Gem::Dependency
|
81
81
|
name: sqlite3-ruby
|
82
|
-
requirement: &
|
82
|
+
requirement: &8618740 !ruby/object:Gem::Requirement
|
83
83
|
none: false
|
84
84
|
requirements:
|
85
85
|
- - ! '>='
|
@@ -87,7 +87,7 @@ dependencies:
|
|
87
87
|
version: '0'
|
88
88
|
type: :development
|
89
89
|
prerelease: false
|
90
|
-
version_requirements: *
|
90
|
+
version_requirements: *8618740
|
91
91
|
description:
|
92
92
|
email: piotr.nielacny@gmail.com
|
93
93
|
executables: []
|
@@ -115,8 +115,10 @@ files:
|
|
115
115
|
- spec/acts-as-messageable_spec.rb
|
116
116
|
- spec/custom-class_spec.rb
|
117
117
|
- spec/custom-required_spec.rb
|
118
|
+
- spec/inheritance_spec.rb
|
118
119
|
- spec/spec_helper.rb
|
119
120
|
- spec/support/admin.rb
|
121
|
+
- spec/support/send_message.rb
|
120
122
|
- spec/support/user.rb
|
121
123
|
homepage: http://github.com/LTe/acts-as-messageable
|
122
124
|
licenses: []
|
@@ -132,7 +134,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
132
134
|
version: '0'
|
133
135
|
segments:
|
134
136
|
- 0
|
135
|
-
hash: -
|
137
|
+
hash: -2807447506494176780
|
136
138
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
137
139
|
none: false
|
138
140
|
requirements:
|