diff options
author | Akihiko Odaki <akihiko.odaki.4i@stu.hosei.ac.jp> | 2017-09-20 01:08:08 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-09-19 18:08:08 +0200 |
commit | bb4d005a8381091911697175416eb9c37379155e (patch) | |
tree | ddd7c17058fa7bf70dbc8ac8d5efa3ec64000680 /spec/services | |
parent | df1ce2350ccbedf145ad9a1b98582610cea80604 (diff) |
Introduce OStatus::TagManager (#5008)
Diffstat (limited to 'spec/services')
-rw-r--r-- | spec/services/authorize_follow_service_spec.rb | 2 | ||||
-rw-r--r-- | spec/services/batched_remove_status_service_spec.rb | 4 | ||||
-rw-r--r-- | spec/services/block_service_spec.rb | 2 | ||||
-rw-r--r-- | spec/services/favourite_service_spec.rb | 2 | ||||
-rw-r--r-- | spec/services/follow_service_spec.rb | 4 | ||||
-rw-r--r-- | spec/services/reject_follow_service_spec.rb | 2 | ||||
-rw-r--r-- | spec/services/remove_status_service_spec.rb | 4 | ||||
-rw-r--r-- | spec/services/unblock_service_spec.rb | 2 | ||||
-rw-r--r-- | spec/services/unfollow_service_spec.rb | 2 |
9 files changed, 12 insertions, 12 deletions
diff --git a/spec/services/authorize_follow_service_spec.rb b/spec/services/authorize_follow_service_spec.rb index d74eb41a2..6ea4d83da 100644 --- a/spec/services/authorize_follow_service_spec.rb +++ b/spec/services/authorize_follow_service_spec.rb @@ -42,7 +42,7 @@ RSpec.describe AuthorizeFollowService do it 'sends a follow request authorization salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:authorize]) + xml.match(OStatus::TagManager::VERBS[:authorize]) }).to have_been_made.once end end diff --git a/spec/services/batched_remove_status_service_spec.rb b/spec/services/batched_remove_status_service_spec.rb index b1e9ac567..f5c9adfb5 100644 --- a/spec/services/batched_remove_status_service_spec.rb +++ b/spec/services/batched_remove_status_service_spec.rb @@ -50,14 +50,14 @@ RSpec.describe BatchedRemoveStatusService do it 'sends PuSH update to PuSH subscribers' do expect(a_request(:post, 'http://example.com/push').with { |req| - matches = req.body.match(TagManager::VERBS[:delete]) + matches = req.body.match(OStatus::TagManager::VERBS[:delete]) }).to have_been_made.at_least_once end it 'sends Salmon slap to previously mentioned users' do expect(a_request(:post, "http://example.com/salmon").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:delete]) + xml.match(OStatus::TagManager::VERBS[:delete]) }).to have_been_made.once end diff --git a/spec/services/block_service_spec.rb b/spec/services/block_service_spec.rb index bd2ab3d53..c69ff7804 100644 --- a/spec/services/block_service_spec.rb +++ b/spec/services/block_service_spec.rb @@ -32,7 +32,7 @@ RSpec.describe BlockService do it 'sends a block salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:block]) + xml.match(OStatus::TagManager::VERBS[:block]) }).to have_been_made.once end end diff --git a/spec/services/favourite_service_spec.rb b/spec/services/favourite_service_spec.rb index 2ab1f32ca..5bf2c74a9 100644 --- a/spec/services/favourite_service_spec.rb +++ b/spec/services/favourite_service_spec.rb @@ -34,7 +34,7 @@ RSpec.describe FavouriteService do it 'sends a salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:favorite]) + xml.match(OStatus::TagManager::VERBS[:favorite]) }).to have_been_made.once end end diff --git a/spec/services/follow_service_spec.rb b/spec/services/follow_service_spec.rb index 1e2378031..ceb39e5e6 100644 --- a/spec/services/follow_service_spec.rb +++ b/spec/services/follow_service_spec.rb @@ -60,7 +60,7 @@ RSpec.describe FollowService do it 'sends a follow request salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:request_friend]) + xml.match(OStatus::TagManager::VERBS[:request_friend]) }).to have_been_made.once end end @@ -81,7 +81,7 @@ RSpec.describe FollowService do it 'sends a follow salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:follow]) + xml.match(OStatus::TagManager::VERBS[:follow]) }).to have_been_made.once end diff --git a/spec/services/reject_follow_service_spec.rb b/spec/services/reject_follow_service_spec.rb index 2e06345b3..bf49dd2c9 100644 --- a/spec/services/reject_follow_service_spec.rb +++ b/spec/services/reject_follow_service_spec.rb @@ -42,7 +42,7 @@ RSpec.describe RejectFollowService do it 'sends a follow request rejection salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:reject]) + xml.match(OStatus::TagManager::VERBS[:reject]) }).to have_been_made.once end end diff --git a/spec/services/remove_status_service_spec.rb b/spec/services/remove_status_service_spec.rb index 8b34bdb6b..b60015928 100644 --- a/spec/services/remove_status_service_spec.rb +++ b/spec/services/remove_status_service_spec.rb @@ -34,7 +34,7 @@ RSpec.describe RemoveStatusService do it 'sends PuSH update to PuSH subscribers' do expect(a_request(:post, 'http://example.com/push').with { |req| - req.body.match(TagManager::VERBS[:delete]) + req.body.match(OStatus::TagManager::VERBS[:delete]) }).to have_been_made end @@ -45,7 +45,7 @@ RSpec.describe RemoveStatusService do it 'sends Salmon slap to previously mentioned users' do expect(a_request(:post, "http://example.com/salmon").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:delete]) + xml.match(OStatus::TagManager::VERBS[:delete]) }).to have_been_made.once end diff --git a/spec/services/unblock_service_spec.rb b/spec/services/unblock_service_spec.rb index def4981e7..ca7a6b77e 100644 --- a/spec/services/unblock_service_spec.rb +++ b/spec/services/unblock_service_spec.rb @@ -34,7 +34,7 @@ RSpec.describe UnblockService do it 'sends an unblock salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:unblock]) + xml.match(OStatus::TagManager::VERBS[:unblock]) }).to have_been_made.once end end diff --git a/spec/services/unfollow_service_spec.rb b/spec/services/unfollow_service_spec.rb index 29040431e..021e76782 100644 --- a/spec/services/unfollow_service_spec.rb +++ b/spec/services/unfollow_service_spec.rb @@ -34,7 +34,7 @@ RSpec.describe UnfollowService do it 'sends an unfollow salmon slap' do expect(a_request(:post, "http://salmon.example.com/").with { |req| xml = OStatus2::Salmon.new.unpack(req.body) - xml.match(TagManager::VERBS[:unfollow]) + xml.match(OStatus::TagManager::VERBS[:unfollow]) }).to have_been_made.once end end |