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
Fix S2094 FP: type specifications, attributes and conditional compilation #6784
Fix S2094 FP: type specifications, attributes and conditional compilation #6784
Conversation
(.NET ITs failed due to a nuget failure, I retried to check if it's intermittent stuff) |
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.
(early feedback even if not yet in review)
analyzers/src/SonarAnalyzer.Common/Rules/ClassShouldNotBeEmptyBase.cs
Outdated
Show resolved
Hide resolved
analyzers/src/SonarAnalyzer.Common/Rules/ClassShouldNotBeEmptyBase.cs
Outdated
Show resolved
Hide resolved
analyzers/tests/SonarAnalyzer.UnitTest/TestCases/ClassShouldNotBeEmpty.Inheritance.cs
Show resolved
Hide resolved
analyzers/tests/SonarAnalyzer.UnitTest/TestCases/ClassShouldNotBeEmpty.cs
Show resolved
Hide resolved
analyzers/tests/SonarAnalyzer.UnitTest/TestCases/ClassShouldNotBeEmpty.cs
Show resolved
Hide resolved
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.
Good stuff!
low ccov is fine for defensive coding
the rspec should be fixed first
Kudos, SonarCloud Quality Gate passed! |
SonarCloud Quality Gate failed. |
The The S2743 code smell is difficult to overcome because of the facade. It could be fixed with a default interface implementation, but the target runtime doesn't support this feature. |
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
Fixes #6704
Exceptions were added for the following test cases:
System.Attribute
or implements theIActionResult
interface in ASP.NETThe rule message was changed to be similar to Java and other languages covering S2094.