about summary refs log tree commit diff
path: root/spec/services/block_domain_from_account_service_spec.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2018-06-09 22:46:54 +0200
committerGitHub <noreply@github.com>2018-06-09 22:46:54 +0200
commit10f51c9886123982bc9f2a95fba39dd1f24b9a05 (patch)
tree16be79ea33b963008b9dada14d4454062bf97b96 /spec/services/block_domain_from_account_service_spec.rb
parent91e5d9f8af3a06c329de4bd603dc904a2a297e15 (diff)
Fix domain hiding logic (#7765)
* Send rejections to followers when user hides domain they're on

* Use account domain blocks for "authorized followers" action

Replace soft-blocking (block & unblock) behaviour with follow rejection

* Split sync and async work of account domain blocking

Do not create domain block when removing followers by domain, that
is probably unexpected from the user's perspective.

* Adjust confirmation message for domain block

* yarn manage:translations
Diffstat (limited to 'spec/services/block_domain_from_account_service_spec.rb')
-rw-r--r--spec/services/block_domain_from_account_service_spec.rb19
1 files changed, 0 insertions, 19 deletions
diff --git a/spec/services/block_domain_from_account_service_spec.rb b/spec/services/block_domain_from_account_service_spec.rb
deleted file mode 100644
index 365c0a4ad..000000000
--- a/spec/services/block_domain_from_account_service_spec.rb
+++ /dev/null
@@ -1,19 +0,0 @@
-require 'rails_helper'
-
-RSpec.describe BlockDomainFromAccountService, type: :service do
-  let!(:wolf) { Fabricate(:account, username: 'wolf', domain: 'evil.org') }
-  let!(:alice) { Fabricate(:account, username: 'alice') }
-
-  subject { BlockDomainFromAccountService.new }
-
-  it 'creates domain block' do
-    subject.call(alice, 'evil.org')
-    expect(alice.domain_blocking?('evil.org')).to be true
-  end
-
-  it 'purge followers from blocked domain' do
-    wolf.follow!(alice)
-    subject.call(alice, 'evil.org')
-    expect(wolf.following?(alice)).to be false
-  end
-end