Skip to content

Update xunit-dotnet monorepo - autoclosed #141

Update xunit-dotnet monorepo - autoclosed

Update xunit-dotnet monorepo - autoclosed #141

Triggered via pull request December 7, 2023 21:27
Status Success
Total duration 5m 58s
Artifacts

codeql-analysis.yml

on: pull_request
Matrix: Analyze
Fit to window
Zoom out
Zoom in

Annotations

10 warnings
Analyze (csharp): src/DummyFileCreator/DummyFile.cs#L95
Use recommended dispose pattern to ensure that object created by 'new DummyFileWriter(filepathToCreate, bufferSize)' is disposed on all paths. If possible, wrap the creation within a 'using' statement or a 'using' declaration. Otherwise, use a try-finally pattern, with a dedicated local variable declared before the try region and an unconditional Dispose invocation on non-null value in the 'finally' region, say 'x?.Dispose()'. If the object is explicitly disposed within the try region or the dispose ownership is transfered to another object or method, assign 'null' to the local variable just after such an operation to prevent double dispose in 'finally'. (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)
Analyze (csharp): src/DummyFileCreator.UnitTests/DummyFileUnitTest.cs#L53
Test methods should not call ConfigureAwait(false), as it may bypass parallelization limits. Omit ConfigureAwait, or use ConfigureAwait(true) to avoid CA2007. (https://xunit.net/xunit.analyzers/rules/xUnit1030)
Analyze (csharp): src/DummyFileCreator.UnitTests/DummyFileUnitTest.cs#L38
Test methods should not call ConfigureAwait(false), as it may bypass parallelization limits. Omit ConfigureAwait, or use ConfigureAwait(true) to avoid CA2007. (https://xunit.net/xunit.analyzers/rules/xUnit1030)
Analyze (csharp): src/DummyFileCreator.UnitTests/DummyFileUnitTest.cs#L55
Test methods should not call ConfigureAwait(false), as it may bypass parallelization limits. Omit ConfigureAwait, or use ConfigureAwait(true) to avoid CA2007. (https://xunit.net/xunit.analyzers/rules/xUnit1030)
Analyze (csharp): src/DummyFileCreator.Console/Program.cs#L13
Prefer 'static readonly' fields over constant array arguments if the called method is called repeatedly and is not mutating the passed array (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1861)
Analyze (csharp): src/DummyFileCreator.Console/Program.cs#L20
Prefer 'static readonly' fields over constant array arguments if the called method is called repeatedly and is not mutating the passed array (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1861)
Analyze (csharp): src/DummyFileCreator.Console/Program.cs#L28
Prefer 'static readonly' fields over constant array arguments if the called method is called repeatedly and is not mutating the passed array (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1861)
Analyze (csharp): src/DummyFileCreator.Console/Program.cs#L33
Prefer 'static readonly' fields over constant array arguments if the called method is called repeatedly and is not mutating the passed array (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca1861)
Analyze (csharp): src/DummyFileCreator.App/Progress/ProgressForm.cs#L115
Dereference of a possibly null reference.
Analyze (csharp): src/DummyFileCreator/DummyFile.cs#L95
Use recommended dispose pattern to ensure that object created by 'new DummyFileWriter(filepathToCreate, bufferSize)' is disposed on all paths. If possible, wrap the creation within a 'using' statement or a 'using' declaration. Otherwise, use a try-finally pattern, with a dedicated local variable declared before the try region and an unconditional Dispose invocation on non-null value in the 'finally' region, say 'x?.Dispose()'. If the object is explicitly disposed within the try region or the dispose ownership is transfered to another object or method, assign 'null' to the local variable just after such an operation to prevent double dispose in 'finally'. (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2000)