Skip to content

Commit 5a94a37

Browse files
Mohammad DehghanMohammad Dehghan
authored andcommitted
Clean some CA complains
1 parent 6534d72 commit 5a94a37

File tree

3 files changed

+3
-7
lines changed

3 files changed

+3
-7
lines changed

SG.CodeCoverage.Recorder/GlobalSuppressions.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@
99
[assembly: SuppressMessage("Design", "CA1031:Do not catch general exception types", Justification = "The exceptions should be sent back to the client that invoked the command.", Scope = "member", Target = "~M:SG.CodeCoverage.Recorder.RecordingController.Server.ProcessCommand(System.String)~System.String")]
1010
[assembly: SuppressMessage("Design", "CA1031:Do not catch general exception types", Justification = "This method is async and is not awaited anywhere, so it should not raise any exceptions.", Scope = "member", Target = "~M:SG.CodeCoverage.Recorder.RecordingController.Server.StartAsync(System.Int32)~System.Threading.Tasks.Task")]
1111
[assembly: SuppressMessage("Design", "CA1031:Do not catch general exception types", Justification = "This method is async and is not awaited anywhere, so it should not raise any exceptions.", Scope = "member", Target = "~M:SG.CodeCoverage.Recorder.RecordingController.Server.AcceptAsync(System.Net.Sockets.TcpClient)~System.Threading.Tasks.Task")]
12+
[assembly: SuppressMessage("Design", "CA1034:Nested types should not be visible", Justification = "This type by itself is not usable outside the containing class, yet it should be visible because it's objects will be used outside.", Scope = "type", Target = "~T:SG.CodeCoverage.Recorder.RecordingController.RuntimeConfig.RunningProcess")]

SG.CodeCoverage.TestConsole/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace SG.CodeCoverage.TestConsole
1111
{
1212
class Program
1313
{
14-
static void Main(string[] args)
14+
static void Main()
1515
{
1616
var tester = new InstrumenterTester();
1717
tester.InstrumentSampleProject();

SG.CodeCoverage/Instrumentation/Instrumenter.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,14 @@ public class Instrumenter
1616
private readonly ILogger _logger;
1717
private readonly ReaderParameters _readerParams;
1818
private readonly WriterParameters _writerParams;
19-
private static readonly string _delegateBaseTypeFullName;
19+
private static readonly string _delegateBaseTypeFullName = typeof(MulticastDelegate).FullName;
2020

2121
public InstrumentationOptions Options { get; }
2222
public string OutputMapFilePath { get; }
2323
public string BackupFolder { get; set; }
2424
public Guid UniqueId { get; private set; }
2525
public string RecorderLogFilePath { get; set; }
2626

27-
static Instrumenter()
28-
{
29-
_delegateBaseTypeFullName = typeof(MulticastDelegate).FullName;
30-
}
31-
3227
/// <summary>
3328
/// </summary>
3429
/// <param name="outputMapFilePath">The path to the output map file (optional)</param>

0 commit comments

Comments
 (0)