mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-13 15:58:50 +00:00
Fix error in CLI EmailDomainBlocks when supplying --with-dns-records (#32863)
This commit is contained in:
@@ -63,6 +63,22 @@ RSpec.describe Mastodon::CLI::EmailDomainBlocks do
|
||||
.and(change(EmailDomainBlock, :count).by(1))
|
||||
end
|
||||
end
|
||||
|
||||
context 'with --with-dns-records true' do
|
||||
let(:domain) { 'host.example' }
|
||||
let(:arguments) { [domain] }
|
||||
let(:options) { { with_dns_records: true } }
|
||||
|
||||
before do
|
||||
configure_mx(domain: domain, exchange: 'other.host')
|
||||
end
|
||||
|
||||
it 'adds a new block for parent and children' do
|
||||
expect { subject }
|
||||
.to output_results('Added 2')
|
||||
.and(change(EmailDomainBlock, :count).by(2))
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
describe '#remove' do
|
||||
|
||||
Reference in New Issue
Block a user