Skip to content
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

Enable nullable for datacollector #3670

Merged
merged 1 commit into from
May 25, 2022
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
6 changes: 2 additions & 4 deletions src/datacollector/DataCollectorMain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@
using CommunicationUtilitiesResources = Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.Resources.Resources;
using CoreUtilitiesConstants = Microsoft.VisualStudio.TestPlatform.CoreUtilities.Constants;

#nullable disable

namespace Microsoft.VisualStudio.TestPlatform.DataCollector;

public class DataCollectorMain
Expand Down Expand Up @@ -70,7 +68,7 @@ internal DataCollectorMain(IProcessHelper processHelper, IEnvironment environmen
_requestHandler = requestHandler;
}

public void Run(string[] args)
public void Run(string[]? args)
{
DebuggerBreakpoint.AttachVisualStudioDebugger("VSTEST_DATACOLLECTOR_DEBUG_ATTACHVS");
DebuggerBreakpoint.WaitForDebugger("VSTEST_DATACOLLECTOR_DEBUG");
Expand Down Expand Up @@ -112,7 +110,7 @@ public void Run(string[] args)

UiLanguageOverride.SetCultureSpecifiedByUser();

EqtTrace.Info("DataCollectorMain.Run: Starting data collector run with args: {0}", string.Join(",", args));
EqtTrace.Info("DataCollectorMain.Run: Starting data collector run with args: {0}", args != null ? string.Join(",", args) : "null");

// Attach to exit of parent process
var parentProcessId = CommandLineArgumentsHelper.GetIntArgFromDict(argsDictionary, ParentProcessArgument);
Expand Down
2 changes: 0 additions & 2 deletions src/datacollector/MessageSink.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
using Microsoft.VisualStudio.TestPlatform.CommunicationUtilities.DataCollection;
using Microsoft.VisualStudio.TestPlatform.ObjectModel.Logging;

#nullable disable

namespace Microsoft.VisualStudio.TestPlatform.DataCollector;

/// <inheritdoc />
Expand Down
4 changes: 1 addition & 3 deletions src/datacollector/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@

using Microsoft.VisualStudio.TestPlatform.ObjectModel;

#nullable disable

namespace Microsoft.VisualStudio.TestPlatform.DataCollector;

/// <summary>
Expand All @@ -20,7 +18,7 @@ public class Program
/// <param name="args">
/// The args.
/// </param>
public static void Main(string[] args)
public static void Main(string[]? args)
{
try
{
Expand Down
5 changes: 3 additions & 2 deletions src/datacollector/PublicAPI/PublicAPI.Shipped.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#nullable enable
Microsoft.VisualStudio.TestPlatform.DataCollector.DataCollectorMain
Microsoft.VisualStudio.TestPlatform.DataCollector.DataCollectorMain.DataCollectorMain() -> void
Microsoft.VisualStudio.TestPlatform.DataCollector.DataCollectorMain.Run(string[] args) -> void
Microsoft.VisualStudio.TestPlatform.DataCollector.DataCollectorMain.Run(string![]? args) -> void
Microsoft.VisualStudio.TestPlatform.DataCollector.Program
Microsoft.VisualStudio.TestPlatform.DataCollector.Program.Program() -> void
static Microsoft.VisualStudio.TestPlatform.DataCollector.Program.Main(string[] args) -> void
static Microsoft.VisualStudio.TestPlatform.DataCollector.Program.Main(string![]? args) -> void