mirror of https://github.com/mastodon/mastodon.git
22 lines
476 B
Ruby
22 lines
476 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'rails_helper'
|
|
|
|
describe AccountFilter do
|
|
describe 'with empty params' do
|
|
it 'excludes instance actor by default' do
|
|
filter = described_class.new({})
|
|
|
|
expect(filter.results).to eq Account.without_instance_actor
|
|
end
|
|
end
|
|
|
|
describe 'with invalid params' do
|
|
it 'raises with key error' do
|
|
filter = described_class.new(wrong: true)
|
|
|
|
expect { filter.results }.to raise_error(/wrong/)
|
|
end
|
|
end
|
|
end
|