Skip to content

Commit 4a74ebf

Browse files
committed
Delete dead code
1 parent d76e16c commit 4a74ebf

File tree

2 files changed

+0
-12
lines changed

2 files changed

+0
-12
lines changed

src/Platform/Microsoft.Testing.Platform/Hosts/TestHostBuilder.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -481,11 +481,6 @@ await LogTestHostCreatedAsync(
481481
policiesService.ProcessRole = TestProcessRole.TestHost;
482482
await proxyOutputDevice.HandleProcessRoleAsync(TestProcessRole.TestHost, testApplicationCancellationTokenSource.CancellationToken).ConfigureAwait(false);
483483

484-
// Setup the test host working folder.
485-
// Out of the test host controller extension the current working directory is the test host working directory.
486-
string? currentWorkingDirectory = configuration[PlatformConfigurationConstants.PlatformCurrentWorkingDirectory];
487-
ApplicationStateGuard.Ensure(currentWorkingDirectory is not null);
488-
489484
testHostControllerInfo.IsCurrentProcessTestHostController = false;
490485

491486
// If we're under test controllers and currently we're inside the started test host we connect to the out of process

src/Platform/Microsoft.Testing.Platform/TestHostControllers/TestHostControllersManager.cs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -108,13 +108,6 @@ public void AddDataConsumer<T>(CompositeExtensionFactory<T> compositeServiceFact
108108

109109
internal async Task<TestHostControllerConfiguration> BuildAsync(ServiceProvider serviceProvider)
110110
{
111-
// For now the test host working directory and the current working directory are the same.
112-
// In future we could move the test host in a different directory for instance in case of
113-
// the need to rewrite binary files. If we don't move files are locked by ourself.
114-
var aggregatedConfiguration = (AggregatedConfiguration)serviceProvider.GetConfiguration();
115-
string? currentWorkingDirectory = aggregatedConfiguration[PlatformConfigurationConstants.PlatformCurrentWorkingDirectory];
116-
ApplicationStateGuard.Ensure(currentWorkingDirectory is not null);
117-
118111
List<(ITestHostEnvironmentVariableProvider TestHostEnvironmentVariableProvider, int RegistrationOrder)> environmentVariableProviders = [];
119112
foreach (Func<IServiceProvider, ITestHostEnvironmentVariableProvider> environmentVariableProviderFactory in _environmentVariableProviderFactories)
120113
{

0 commit comments

Comments
 (0)