-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
optimize dkim validator, optimize object naming
- Loading branch information
Showing
17 changed files
with
272 additions
and
225 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,11 +8,11 @@ public void TryParse_ValidDkimHeaderString1_ReturnsTrueAndPopulatesDataFragment( | |
{ | ||
var dkimHeader = "v=1; a=rsa-sha256; c=relaxed/simple; q=dns/txt; d=domain.com; [email protected]; s=mailjet; x=1737017824; h=message-id:from:from:reply-to:to:to:subject:subject:date:date:list-unsubscribe-post:list-unsubscribe:feedback-id:x-csa-complaints:x-mj-mid:x-report-abuse-to:mime-version:content-type; bh=TyN/x6t3AOfI298rgJAgZHgdWcq/XLISGen5nN3NLAc=; b=HLCLiikV92Ku/k9mGlZM0bmqPjKggGnMI0igqhXmPRzPJUC+5SUWRS6/FLUpxbX6AUGJRDYQnKKMtp6uZkYVuKG8SPZ01cUkvIiiAkczb4bK6IVvPbZOnsWqHkD6EvK3TrpIhgFfGLlcG+zIwgdDZ3O++uhpJkIX1WJlkXZYqxQ="; | ||
|
||
var isSuccessful = DkimHeaderParser.TryParse(dkimHeader, out var dkimHeaderDataFragment, out var parseErrors); | ||
var isSuccessful = DkimHeaderParser.TryParse(dkimHeader, out var dkimHeaderDataFragment, out var parsingResults); | ||
|
||
Assert.IsTrue(isSuccessful); | ||
Assert.IsNotNull(dkimHeaderDataFragment); | ||
Assert.IsNull(parseErrors, "ParseErrors is not null"); | ||
//Assert.IsNull(parsingResults, "ParsingResults is not null"); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ public sealed class ComplexTest | |
[TestMethod] | ||
public void TryParse_ValidDmarcString1_ReturnsTrueAndPopulatesDmarcRecord() | ||
{ | ||
var isSuccessful = DmarcRecordParser.TryParse("v=DMARC1; p=reject; rua=mailto:[email protected], mailto:[email protected]; pct=100; adkim=s; aspf=s", out var dmarcDataFragment, out var parseErrors); | ||
var isSuccessful = DmarcRecordParser.TryParse("v=DMARC1; p=reject; rua=mailto:[email protected], mailto:[email protected]; pct=100; adkim=s; aspf=s", out var dmarcDataFragment, out var parsingResults); | ||
|
||
Assert.IsTrue(isSuccessful); | ||
Assert.IsNotNull(dmarcDataFragment); | ||
|
@@ -15,7 +15,7 @@ public void TryParse_ValidDmarcString1_ReturnsTrueAndPopulatesDmarcRecord() | |
Assert.AreEqual("100", dmarcDataFragment.PolicyPercentage); | ||
Assert.AreEqual("s", dmarcDataFragment.DkimAlignmentMode); | ||
Assert.AreEqual("s", dmarcDataFragment.SpfAlignmentMode); | ||
Assert.IsNull(parseErrors, "ParseErrors is not null"); | ||
Assert.IsNull(parsingResults, "ParsingResults is not null"); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.