FIX: Do not validate messages sent to mailing list mirror

This commit is contained in:
Gerhard Schlager 2018-01-04 13:39:29 +01:00
parent e0d73a957d
commit f086d28b30
2 changed files with 10 additions and 0 deletions

View File

@ -818,6 +818,16 @@ describe Email::Receiver do
expect { process(:mailinglist_reply) }.to change { topic.posts.count }
end
it "should skip validations for staged users" do
Fabricate(:user, email: "alice@foo.com", staged: true)
expect { process(:mailinglist_short_message) }.to change { Topic.count }
end
it "should skip validations for regular users" do
Fabricate(:user, email: "alice@foo.com")
expect { process(:mailinglist_short_message) }.to change { Topic.count }
end
context "read-only category" do
before do
category.set_permissions(everyone: :readonly)

Binary file not shown.