Skip to content

chore: implement test cases for types of References in an OpenApi document #2006

chore: implement test cases for types of References in an OpenApi document

chore: implement test cases for types of References in an OpenApi document #2006

Triggered via pull request May 19, 2025 09:43
Status Success
Total duration 4m 47s
Artifacts

sonarcloud.yml

on: pull_request
check if SONAR_TOKEN is set in github secrets
2s
check if SONAR_TOKEN is set in github secrets
Fit to window
Zoom out
Zoom in

Annotations

10 warnings
Build: src/Microsoft.OpenApi/Models/OpenApiReference.cs#L103
Change this condition so that it does not always evaluate to 'True'. (https://rules.sonarsource.com/csharp/RSPEC-2589)
Build: src/Microsoft.OpenApi/Reader/ParseNodes/MapNode.cs#L198
Remove this unnecessary check for null. (https://rules.sonarsource.com/csharp/RSPEC-2589)
Build: src/Microsoft.OpenApi/Reader/ParseNodes/MapNode.cs#L35
Remove this unnecessary cast to 'IEnumerable<KeyValuePair<string, JsonNode>>'. (https://rules.sonarsource.com/csharp/RSPEC-1905)
Build: src/Microsoft.OpenApi/Services/OpenApiWorkspace.cs#L374
Refactor this method to reduce its Cognitive Complexity from 17 to the 15 allowed. (https://rules.sonarsource.com/csharp/RSPEC-3776)
Build: src/Microsoft.OpenApi/Services/OpenApiWorkspace.cs#L275
Change this condition so that it does not always evaluate to 'True'. (https://rules.sonarsource.com/csharp/RSPEC-2589)
Build: src/Microsoft.OpenApi/Services/OpenApiWorkspace.cs#L88
Refactor this method to reduce its Cognitive Complexity from 31 to the 15 allowed. (https://rules.sonarsource.com/csharp/RSPEC-3776)
Build: src/Microsoft.OpenApi/Reader/V31/OpenApiSchemaDeserializer.cs#L206
Loops should be simplified using the "Where" LINQ method (https://rules.sonarsource.com/csharp/RSPEC-3267)
Build: src/Microsoft.OpenApi/Models/OpenApiReference.cs#L74
Make this an auto-implemented property and remove its backing field. (https://rules.sonarsource.com/csharp/RSPEC-2292)
Build: src/Microsoft.OpenApi/Reader/V31/OpenApiSchemaDeserializer.cs#L19
Refactor this field to reduce its Cognitive Complexity from 52 to the 15 allowed. (https://rules.sonarsource.com/csharp/RSPEC-3776)
Build: src/Microsoft.OpenApi/Reader/V31/OpenApiSchemaDeserializer.cs#L405
Possible null reference argument for parameter 'id' in 'bool OpenApiWorkspace.RegisterComponentForDocument<OpenApiSchema>(OpenApiDocument openApiDocument, OpenApiSchema componentToRegister, string id)'.