2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-06 09:10:25 +08:00

FEATURE: add support for multiple incoming emails for groups & categories

This commit is contained in:
Régis Hanol 2016-02-24 19:47:58 +01:00
parent 54262cc9b2
commit f7432d8ec9
8 changed files with 26 additions and 12 deletions

View file

@ -223,7 +223,7 @@ describe Email::Receiver do
context "new message to a group" do
let!(:group) { Fabricate(:group, incoming_email: "team@bar.com") }
let!(:group) { Fabricate(:group, incoming_email: "team@bar.com|meat@bar.com") }
it "handles encoded display names" do
expect { process(:encoded_display_name) }.to change(Topic, :count)
@ -275,7 +275,7 @@ describe Email::Receiver do
context "new topic in a category" do
let!(:category) { Fabricate(:category, email_in: "category@bar.com", email_in_allow_strangers: false) }
let!(:category) { Fabricate(:category, email_in: "category@bar.com|category@foo.com", email_in_allow_strangers: false) }
it "raises a StrangersNotAllowedError when 'email_in_allow_strangers' is disabled" do
expect { process(:new_user) }.to raise_error(Email::Receiver::StrangersNotAllowedError)