Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/diaspora/diaspora.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/workers/fetch_webfinger_spec.rb')
-rw-r--r--spec/workers/fetch_webfinger_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/workers/fetch_webfinger_spec.rb b/spec/workers/fetch_webfinger_spec.rb
index cfa83b24a..0a9469c75 100644
--- a/spec/workers/fetch_webfinger_spec.rb
+++ b/spec/workers/fetch_webfinger_spec.rb
@@ -3,7 +3,7 @@ require "spec_helper"
describe Workers::FetchWebfinger do
it "should webfinger and queue a job to fetch public posts" do
@person = FactoryGirl.create(:person)
- allow(Webfinger).to receive(:new).and_return(double(fetch: @person))
+ allow(Person).to receive(:find_or_fetch_by_identifier).and_return(@person)
expect(Diaspora::Fetcher::Public).to receive(:queue_for).exactly(1).times
@@ -11,7 +11,7 @@ describe Workers::FetchWebfinger do
end
it "should webfinger and queue no job to fetch public posts if the person is not found" do
- allow(Webfinger).to receive(:new).and_return(double(fetch: nil))
+ allow(Person).to receive(:find_or_fetch_by_identifier).and_return(nil)
expect(Diaspora::Fetcher::Public).not_to receive(:queue_for)