|
|
|
@ -196,6 +196,28 @@ RSpec.describe FeedManager do
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
context 'with list feed' do
|
|
|
|
|
let(:list) { Fabricate(:list, account: bob) }
|
|
|
|
|
|
|
|
|
|
before do
|
|
|
|
|
bob.follow!(alice)
|
|
|
|
|
list.list_accounts.create!(account: alice)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
it "returns false for followee's status" do
|
|
|
|
|
status = Fabricate(:status, text: 'Hello world', account: alice)
|
|
|
|
|
|
|
|
|
|
expect(subject.filter?(:list, status, list)).to be false
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
it 'returns false for reblog by followee' do
|
|
|
|
|
status = Fabricate(:status, text: 'Hello world', account: jeff)
|
|
|
|
|
reblog = Fabricate(:status, reblog: status, account: alice)
|
|
|
|
|
|
|
|
|
|
expect(subject.filter?(:list, reblog, list)).to be false
|
|
|
|
|
end
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
context 'with mentions feed' do
|
|
|
|
|
it 'returns true for status that mentions blocked account' do
|
|
|
|
|
bob.block!(jeff)
|
|
|
|
|