fixed a broken common.rb spec
This commit is contained in:
parent
6467f943da
commit
c99416ca67
2 changed files with 3 additions and 3 deletions
|
|
@ -7,7 +7,7 @@ module Diaspora
|
||||||
|
|
||||||
def notify_friends
|
def notify_friends
|
||||||
if self.person_id == User.first.id
|
if self.person_id == User.first.id
|
||||||
xml = Post.build_xml_for(self)
|
xml = Post.build_xml_for([self])
|
||||||
@@queue.add_post_request( friends_with_permissions, CGI::escape(xml) )
|
@@queue.add_post_request( friends_with_permissions, CGI::escape(xml) )
|
||||||
@@queue.process
|
@@queue.process
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -59,8 +59,8 @@ describe Diaspora do
|
||||||
end
|
end
|
||||||
|
|
||||||
it "should send an owners post to their friends" do
|
it "should send an owners post to their friends" do
|
||||||
Post.stub(:build_xml_for).and_return(true)
|
q = Post.send (:class_variable_get, :@@queue)
|
||||||
Post.should_receive(:build_xml_for).and_return true
|
q.should_receive :process
|
||||||
@post.save
|
@post.save
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue