Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .sonarcloud.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Automatic analysis reads this file instead of sonar-project.properties.
# Use literal paths: wildcard patterns are not supported by automatic analysis.
# Preserve the files covered by the existing build/common/Addins/**/* exclusion.
# Add new vendored addin files here to retain that exclusion as the directory grows.
sonar.exclusions=\
build/common/Addins/Cake.Docker/DockerBuildXBuildSettings.cs,\
build/common/Addins/Cake.Docker/DockerBuildXImageToolsCreateSettings.cs,\
build/common/Addins/Cake.Docker/Constants.cs,\
build/common/Addins/GitVersion/GitVersionVerbosity.cs,\
build/common/Addins/GitVersion/GitVersion.cs,\
build/common/Addins/GitVersion/GitVersionAliases.cs,\
build/common/Addins/GitVersion/GitVersionOutput.cs,\
build/common/Addins/GitVersion/GitVersionSettings.cs,\
build/common/Addins/GitVersion/GitVersionRunner.cs,\
src/GitVersion.Output/GitVersionInfo/Templates/GitVersionInformation.vb,\
src/GitVersion.Output/GitVersionInfo/AddFormats/GitVersionInformation.vb,\
src/GitVersion.Output/AssemblyInfo/Templates/VersionAssemblyInfo.vb,\
src/GitVersion.Output/AssemblyInfo/AddFormats/VersionAssemblyInfo.vb

# The VB files are embedded generation templates/fragments, not a VB project.
# Excluding them avoids the synthetic orphan-project S6145 finding.
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,9 @@ public record TestCommandSettings : GitVersionSettings

""";

#pragma warning disable S2699 // RunAsync verifies diagnostics and all expected generated sources; Sonar does not collect NOSONAR lines for test projects.
[Test]
public async Task ValidateGeneratedCommandImplementation() // NOSONAR: RunAsync verifies diagnostics and all expected generated sources.
public async Task ValidateGeneratedCommandImplementation()
{
var generatorType = typeof(SystemCommandlineGenerator);
var encoding = Encoding.UTF8;
Expand Down Expand Up @@ -288,4 +289,5 @@ public async Task ValidateGeneratedCommandImplementation() // NOSONAR: RunAsync
});
await sourceGeneratorTest.RunAsync();
}
#pragma warning restore S2699
}
Loading