-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add C# 9 tests for 5 rules #3713
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Just a few minor comments.
@@ -47,6 +47,15 @@ public class CookieShouldBeHttpOnlyTest | |||
new CookieShouldBeHttpOnly(AnalyzerConfiguration.AlwaysEnabled), | |||
additionalReferences: GetAdditionalReferences_NetCore()); | |||
|
|||
[TestMethod] | |||
[TestCategory("Rule")] | |||
public void CookiesShouldBeHttpOnly_NetCore_CSharp9() => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pedantic: this is now just ".Net" :)
@@ -64,6 +64,15 @@ public class CookieShouldBeSecureTest | |||
new CookieShouldBeSecure(AnalyzerConfiguration.AlwaysEnabled), | |||
additionalReferences: GetAdditionalReferences_NetCore()); | |||
|
|||
[TestMethod] | |||
[TestCategory("Rule")] | |||
public void CookiesShouldBeSecure_NetCore_CSharp9() => |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pedantic: like in previous comment, I would remove the mention of the framework
{ | ||
void IsPattern() | ||
{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pedantic: empty line
|
||
void IsNotPattern() | ||
{ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pedantic: empty line
se also in the other methods
// See https://github.com/dotnet/roslyn/issues/45510 | ||
namespace System.Runtime.CompilerServices | ||
{ | ||
public class IsExternalInit { } | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you need to rebase on master and remove this, otherwise this will break the build after merge.
See also the other files.
6db70c0
to
8d03f12
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs |
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Related to #3668