Contact: Friendly Captcha v2, opstartvalidatie, ASF-host met Contact-module en hosttests (CMS-U9)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -107,6 +107,20 @@ public class ContactMailSenderTests
|
||||
rig.Sent.TextBody.Should().Contain("regel2").And.Contain("Naam:");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public async Task ASubjectLabelWithSpecialCharacters_IsEncodedInTheBody_AndNeverReachesTheSubjectOrAHeader()
|
||||
{
|
||||
var rig = new Rig();
|
||||
const string label = "Fotoshoot & <b>\"bruiloft\"</b> 'zomer'";
|
||||
|
||||
await rig.Build().SendAsync(Message(subject: label), CancellationToken.None);
|
||||
|
||||
rig.Sent!.Subject.Should().Be("Nieuw bericht via De Site");
|
||||
rig.Sent.HtmlBody.Should().Contain("Fotoshoot & <b>").And.NotContain("<b>\"bruiloft\"");
|
||||
rig.Sent.TextBody.Should().Contain(" " + label);
|
||||
rig.Sent.ReplyToAddress.Should().Be(Visitor);
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public async Task English_UsesEnglishLabelsAndSubject()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user