Add: 検索許可「ローカルとフォロワー」 (#60)

This commit is contained in:
KMY(雪あすか) 2023-10-05 16:37:27 +09:00 committed by GitHub
parent deb8642e95
commit 235bef36d0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 210 additions and 25 deletions

View file

@ -63,6 +63,45 @@ describe StatusesSearchService do
end
end
context 'when public_unlisted searchability' do
let(:searchability) { :public_unlisted }
let(:account) { other }
context 'with other account' do
it 'search status' do
expect(subject.count).to eq 1
expect(subject).to include status.id
end
end
context 'with follower' do
let(:account) { following }
it 'search status' do
expect(subject.count).to eq 1
expect(subject).to include status.id
end
end
context 'with reacted user' do
let(:account) { reacted }
it 'search status' do
expect(subject.count).to eq 1
expect(subject).to include status.id
end
end
context 'with self' do
let(:account) { alice }
it 'search status' do
expect(subject.count).to eq 1
expect(subject).to include status.id
end
end
end
context 'when private searchability' do
let(:searchability) { :private }
let(:account) { other }