diff options
author | Benjamin Neff <benjamin@coding4coffee.ch> | 2015-08-09 02:53:31 +0300 |
---|---|---|
committer | Jonne Haß <me@jhass.eu> | 2015-08-21 15:21:43 +0300 |
commit | d28e03f053ae47d215b0d87b7a452e92c07cb167 (patch) | |
tree | 7f7867be5d5da407d121dd8a24cfd8738ecf8dbb /spec/workers | |
parent | 21e5bd869748f667f00771487e64dd835b061316 (diff) |
use discovery from diaspora_federation gem
Diffstat (limited to 'spec/workers')
-rw-r--r-- | spec/workers/fetch_webfinger_spec.rb | 4 |
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) |