vstest: [17.3.0] Testhost process exited with error: Cannot use file stream for [...\bin\Debug\net6.0\testhost.deps.json]: No such file or directory

Description

Testing fails with VSTest 17.3.0 in an Azure DevOps pipeline and produces the following errors:

[error]Testhost process exited with error: Cannot use file stream for [...\bin\Debug\net6.0\testhost.deps.json]: No such file or directory
[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
[error]Failed to run as a self-contained app.
[error]  - The application was run as a self-contained app because '...\bin\Debug\net6.0\testhost.runtimeconfig.json' was not found.
[error]  - If this should be a framework-dependent app, add the '...\bin\Debug\net6.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
[error]. Please check the diagnostic logs for more information.

Downgrading the version to 17.2.0 passes successfully.

Steps to reproduce

  1. Set Azure DevOps pipeline to install the latest VsTest platform.
  2. Set Azure DevOps pipeline to run tests with the below settings:
Running tests using vstest.console.exe runner.
======================================================
Test selector : Test assemblies
Test filter criteria : null
Search folder : C:\..\..\_w\212\s
Action when minimum tests threshold not met : donothing
Minimum tests expected to be run: 0
Run in parallel : false
Run in isolation : false
Path to custom adapters : null
Other console options : null
Code coverage enabled : true
Diagnostics enabled : true
SystemVssConnection exists true
Run the tests locally using vstest.console.exe
========================================================
Source filter: **\*test*.dll,!**\obj\**,!**\<project name>.Tests\**

Expected behavior

Testing should succeed as it did previously with version 17.2.0.

Actual behavior

Testing fails with version 17.3.0 and the above errors.

Diagnostic logs

VsTestLogs.txt

Environment

OS Name: Microsoft Windows Server 2019 Standard Version: 10.0.17763 Build 17763 Console Version: VsTest\17.3.0\x64\tools\net451\Common7\IDE\Extensions\TestPlatform\vstest.console.exe

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 1
  • Comments: 38 (14 by maintainers)

Most upvoted comments

It seems that your run includes a lot of dlls that don’t contain tests, and most of the error out, but it also tries to run tests from testhost.dll, could you try changing the filter to follow your naming convention, so it only matches *Tests.dll?

From: Source filter: **\*test*.dll,!**\obj\**,!**\<Function App Project Name>.Tests\** To: Source filter: **\*Tests.dll,!**\obj\**,!**\<Function App Project Name>.Tests\**

@nohwnd Implementing a breaking change in this manner is unacceptable regardless of whether it makes the behaviour more “correct” (for your value of “correct”) or not. I, and most affected developers, consider “correct” to be “our test run doesn’t arbitrarily break out of the blue when I perform a minor version upgrade of a NuGet package”.

You do NOT, EVER, release a breaking change without first communicating it to end-users. You do NOT, EVER, release a breaking change as a minor version.

The right way to implement a breaking change is to release a version of the package that causes a warning to be raised around said change, while at the same time releasing a blog post/other communication indicating the behaviour indicated by the warning is going to become the default in the next MAJOR (not minor) version of vstest (because it’s a breaking change), and then implementing said behaviour in said major version.

Roll back this change and follow the process I’ve outlined above, which is basic software engineering discipline for decades, and stop causing unnecessary problems for developers.

I understand this is caused by the default filter picking up dlls that it’s not meant to and searching them for unit tests, but why is this suddenly a problem now? What changed? Have the default filters changed or is it the way it matches files?

https://github.com/microsoft/vstest/issues/3937#issuecomment-1236725873

I am sorry to say but I will call its a very bad decision by the team. If you going to break lot of consumers then you should at least prior inform them.

I have updated to this,

- task: VSTest@2
  inputs:
    platform: '$(buildPlatform)'
    configuration: '$(buildConfiguration)'
    testSelector: 'testAssemblies'
    testAssemblyVer2: |
      **\*UnitTest*.dll
      !**\*TestAdapter.dll
      !**\obj\**
    searchFolder: '$(System.DefaultWorkingDirectory)'  

and it worked like a charm but I don’t think its good idea from VsTest to break the running pipelines suddenly, thanks @nickyquinn and @nohwnd 😃

We have had the same problem in my team and changing the filter works OK, thank you @nohwnd 😃

I understand this is caused by the default filter picking up dlls that it’s not meant to and searching them for unit tests, but why is this suddenly a problem now? What changed? Have the default filters changed or is it the way it matches files?

This changed, .NET “Core” dlls were silently ignored if there was at least one .NET Framework dll in the mix. Which causes tests to be lost. https://github.com/microsoft/vstest/issues/3937#issuecomment-1236725873

@snakefoot We are going to publish a fix for 17.3.1 that should make the issue smaller, but it won’t completely go away, because we are no longer silently ignoring .NET dlls that are added to the test run together with .NET Framework assemblies.

Solution is to use appropriate filter that only selects your tested dlls, usually a the small one with bin\ in it should work.

@nohwnd its auto generated YAML by Azure DevOps.

Here are the VsTests logs.

2022-08-18T07:44:32.9384894Z ##[section]Starting: VSTest
2022-08-18T07:44:32.9534755Z ==============================================================================
2022-08-18T07:44:32.9535070Z Task         : Visual Studio Test
2022-08-18T07:44:32.9535757Z Description  : Run unit and functional tests (Selenium, Appium, Coded UI test, etc.) using the Visual Studio Test (VsTest) runner. Test frameworks that have a Visual Studio test adapter such as MsTest, xUnit, NUnit, Chutzpah (for JavaScript tests using QUnit, Mocha and Jasmine), etc. can be run. Tests can be distributed on multiple agents using this task (version 2).
2022-08-18T07:44:32.9536419Z Version      : 2.205.0
2022-08-18T07:44:32.9536617Z Author       : Microsoft Corporation
2022-08-18T07:44:32.9536884Z Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/test/vstest
2022-08-18T07:44:32.9537204Z ==============================================================================
2022-08-18T07:44:33.7186956Z SystemVssConnection exists true
2022-08-18T07:44:33.8345440Z SystemVssConnection exists true
2022-08-18T07:44:33.9262783Z Running tests using vstest.console.exe runner.
2022-08-18T07:44:33.9263459Z ======================================================
2022-08-18T07:44:33.9264719Z Test selector : Test assemblies
2022-08-18T07:44:33.9266050Z Test filter criteria : null
2022-08-18T07:44:33.9267009Z Search folder : D:\a\1\s
2022-08-18T07:44:33.9794749Z Action when minimum tests threshold not met : donothing
2022-08-18T07:44:33.9795120Z Minimum tests expected to be run: 0
2022-08-18T07:44:33.9796297Z VisualStudio version selected for test execution : latest
2022-08-18T07:44:33.9799461Z Attempting to find vstest.console from a visual studio installation with version [17.0,18.0).
2022-08-18T07:44:33.9876029Z Run in parallel : false
2022-08-18T07:44:33.9877016Z Run in isolation : false
2022-08-18T07:44:33.9878752Z Path to custom adapters : null
2022-08-18T07:44:33.9881681Z Other console options : null
2022-08-18T07:44:33.9882255Z Code coverage enabled : false
2022-08-18T07:44:33.9884884Z Diagnostics enabled : false
2022-08-18T07:44:33.9887296Z SystemVssConnection exists true
2022-08-18T07:44:33.9920659Z Run the tests locally using vstest.console.exe
2022-08-18T07:44:33.9921409Z ========================================================
2022-08-18T07:44:34.0005531Z Source filter: **\*test*.dll,!**\*TestAdapter.dll,!**\obj\**
2022-08-18T07:44:34.2143773Z SystemVssConnection exists true
2022-08-18T07:44:34.2146701Z [command]D:\a\_tasks\VSTest_ef087383-ee5e-42c7-9a53-ab56c98420f9\2.205.0\Modules\DTAExecutionHost.exe --inputFile D:\a\_temp\input_9a24dbc1-1ec9-11ed-8862-158b99d69f7a.json
2022-08-18T07:44:34.2147441Z ======================================================
2022-08-18T07:44:34.2578119Z ##########################################################################
2022-08-18T07:44:34.2578617Z DtaExecutionHost version 19.204.32418.1.
2022-08-18T07:44:34.5705501Z Starting TestExecution Model...
2022-08-18T07:44:37.1734744Z Result Attachments will be stored in LogStore
2022-08-18T07:44:37.1943905Z Run Attachments will be stored in LogStore
2022-08-18T07:44:37.2021085Z Result Attachments will be stored in LogStore
2022-08-18T07:44:37.2655661Z Result Attachments will be stored in LogStore
2022-08-18T07:44:37.2656354Z Run Attachments will be stored in LogStore
2022-08-18T07:44:37.2935710Z Updated Run Settings:
2022-08-18T07:44:37.2946997Z <RunSettings>
2022-08-18T07:44:37.2947491Z   <RunConfiguration>
2022-08-18T07:44:37.2947901Z     <BatchSize>1000</BatchSize>
2022-08-18T07:44:37.2948214Z     <ResultsDirectory>D:\a\_temp\TestResults</ResultsDirectory>
2022-08-18T07:44:37.2948511Z   </RunConfiguration>
2022-08-18T07:44:37.2948731Z </RunSettings>
2022-08-18T07:44:37.3033564Z **************** Starting test execution *********************
2022-08-18T07:44:37.3139196Z [command]C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\IDE\Extensions\TestPlatform\vstest.console.exe "@D:\a\_temp\awxtuei5bem.tmp"
2022-08-18T07:44:37.4327933Z Microsoft (R) Test Execution Command Line Tool Version 17.3.0-preview-20220626-01 (x64)
2022-08-18T07:44:37.4328771Z Copyright (c) Microsoft Corporation.  All rights reserved.
2022-08-18T07:44:37.4452195Z vstest.console.exe "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.TestPlatform.CommunicationUtilities.dll"
2022-08-18T07:44:37.4453216Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.TestPlatform.CoreUtilities.dll"
2022-08-18T07:44:37.4454116Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.TestPlatform.CrossPlatEngine.dll"
2022-08-18T07:44:37.4454985Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.TestPlatform.PlatformAbstractions.dll"
2022-08-18T07:44:37.4455712Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.TestPlatform.Utilities.dll"
2022-08-18T07:44:37.4456401Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.VisualStudio.TestPlatform.Common.dll"
2022-08-18T07:44:37.4457108Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\Microsoft.VisualStudio.TestPlatform.ObjectModel.dll"
2022-08-18T07:44:37.4457829Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\MyProject.UnitTest.dll"
2022-08-18T07:44:37.4458310Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4458822Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4459334Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4459841Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4460353Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4460932Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4461439Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4461924Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4462637Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4463150Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4463665Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4464168Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4464659Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4465151Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4465666Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4466191Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4466687Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4467175Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4467671Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4468166Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4468682Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4469870Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4470359Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4470861Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4472132Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4473218Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4474075Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4474584Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4475089Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4475611Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4476530Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4477035Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4477518Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4478017Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4478527Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4479038Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4479662Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4480155Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4480641Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4481151Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4481682Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4482186Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4482696Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4483211Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4483738Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4484261Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4484762Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4485242Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4485742Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4486696Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4487125Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.dll"
2022-08-18T07:44:37.4487569Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4488072Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4488545Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4489050Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4489565Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4490089Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4490617Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4491127Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4491636Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4492164Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4492701Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CommunicationUtilities.resources.dll"
2022-08-18T07:44:37.4493201Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CoreUtilities.resources.dll"
2022-08-18T07:44:37.4493711Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CrossPlatEngine.resources.dll"
2022-08-18T07:44:37.4494235Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.VisualStudio.TestPlatform.Common.resources.dll"
2022-08-18T07:44:37.4494812Z "D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll"
2022-08-18T07:44:37.4495242Z /Settings:"D:\a\_temp\lzjliefozek.tmp.runsettings"
2022-08-18T07:44:37.4495503Z /Logger:"trx"
2022-08-18T07:44:37.4495721Z /TestAdapterPath:"D:\a\1\s"
2022-08-18T07:44:38.5978059Z Starting test execution, please wait...
2022-08-18T07:44:39.0583451Z A total of 74 test files matched the specified pattern.
2022-08-18T07:44:39.3379713Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.3382058Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.3384047Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.3391528Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.3399316Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.3403372Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.4251625Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.4257137Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.4259757Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.4262571Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.4265784Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.4267925Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.4529251Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.4531970Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.4533611Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.4538367Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.4540269Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.4541627Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.4818673Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.4821178Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.4822780Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.4824696Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.4827178Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.4829056Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.5112681Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.5115100Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.5116715Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.5118493Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.5120323Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.5121453Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.5465969Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.5469470Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.5471240Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.5473847Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.5476783Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.5478650Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.5736283Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.5739001Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.5740478Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.5742457Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.5744267Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.5745585Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:39.6020355Z ##[error]Testhost process exited with error: Cannot use file stream for [D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.deps.json]: No such file or directory
2022-08-18T07:44:39.6022742Z ##[error]A fatal error was encountered. The library 'hostpolicy.dll' required to execute the application was not found in 'C:\Program Files\dotnet'.
2022-08-18T07:44:39.6024296Z ##[error]Failed to run as a self-contained app.
2022-08-18T07:44:39.6026170Z ##[error]  - The application was run as a self-contained app because 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' was not found.
2022-08-18T07:44:39.6028429Z ##[error]  - If this should be a framework-dependent app, add the 'D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\testhost.runtimeconfig.json' file and specify the appropriate framework.
2022-08-18T07:44:39.6030754Z ##[error]. Please check the diagnostic logs for more information.
2022-08-18T07:44:43.7032915Z [xUnit.net 00:00:00.00] xUnit.net VSTest Adapter v2.4.3+1b45f5407b (64-bit .NET 5.0.17)
2022-08-18T07:44:48.1545371Z [xUnit.net 00:00:04.49]   Discovering: MyProject.UnitTest
2022-08-18T07:44:48.4409646Z [xUnit.net 00:00:04.77]   Discovered:  MyProject.UnitTest
2022-08-18T07:44:48.4412006Z [xUnit.net 00:00:04.77]   Starting:    MyProject.UnitTest
2022-08-18T07:44:50.3821550Z   Passed MyProject.UnitTest..............

Passed Tests are Removed For Bravity

2022-08-18T07:44:50.4954234Z   Passed MyProject.UnitTest..............
2022-08-18T07:44:51.0574895Z [xUnit.net 00:00:07.39]   Finished:    MyProject.UnitTest
2022-08-18T07:44:51.6314234Z   Passed MyProject.UnitTest...............................

Passed Tests are Removed For Bravity

2022-08-18T07:44:51.7101590Z   Passed MyProject.UnitTest............................
2022-08-18T07:44:53.8758348Z No test is available in D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\cs\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\de\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\es\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\fr\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\it\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ja\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ko\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pl\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\pt-BR\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\ru\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\tr\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hans\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CommunicationUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CoreUtilities.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.TestPlatform.CrossPlatEngine.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.VisualStudio.TestPlatform.Common.resources.dll D:\a\1\s\MyProject.UnitTest\bin\Release\net5.0\zh-Hant\Microsoft.VisualStudio.TestPlatform.ObjectModel.resources.dll. Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again.
2022-08-18T07:44:54.1411882Z Results File: D:\a\_temp\TestResults\VssAdministrator_WIN-JFKRREF8GOL_2022-08-18_07_44_50.trx
2022-08-18T07:44:54.1601866Z Total tests: Unknown
2022-08-18T07:44:54.1603153Z ##[error]Test Run Aborted.
2022-08-18T07:44:54.1604317Z      Passed: 673
2022-08-18T07:44:54.1616214Z  Total time: 14.9030 Seconds
2022-08-18T07:44:54.1994092Z Vstest.console.exe exited with code 1.
2022-08-18T07:44:54.1994732Z **************** Completed test execution *********************
2022-08-18T07:44:54.2081136Z Test results files: D:\a\_temp\TestResults\VssAdministrator_WIN-JFKRREF8GOL_2022-08-18_07_44_50.trx
2022-08-18T07:44:55.0843729Z Created test run: 5790
2022-08-18T07:44:55.0845870Z Publishing test results: 444
2022-08-18T07:44:55.1718854Z Publishing test results to test run '5790'.
2022-08-18T07:44:55.1746315Z TestResults To Publish 444, Test run id:5790
2022-08-18T07:44:55.1840552Z Test results publishing 444, remaining: 0. Test run id: 5790
2022-08-18T07:44:55.7901440Z Published test results: 444
2022-08-18T07:44:55.7905237Z Publishing Attachments: 1
2022-08-18T07:44:56.8842814Z Execution Result Code 1 is non zero, checking for failed results
2022-08-18T07:44:57.2237946Z Completed TestExecution Model...
2022-08-18T07:44:57.2461826Z ##[warning]Vstest failed with error. Check logs for failures. There might be failed tests.
2022-08-18T07:44:57.2464649Z ##[error]Error: The process 'D:\a\_tasks\VSTest_ef087383-ee5e-42c7-9a53-ab56c98420f9\2.205.0\Modules\DTAExecutionHost.exe' failed with exit code 1
2022-08-18T07:44:57.2469719Z ##[error]Vstest failed with error. Check logs for failures. There might be failed tests.
2022-08-18T07:44:57.2621837Z ##[section]Finishing: VSTest