@Emanuel Jiménez Welcome to Microsoft Q&A Forum, Thank you for posting your query here!
I see that you're encountering an error when running a pipeline to test a project. The error message indicates that the reference assemblies for ".NETFramework,Version=v6.0" were not found. This error suggests that you might be using an older .NET SDK to target .NET 5.0 or higher.
To resolve the error, you can try the following troubleshooting steps:
- While migrating an app to .NET 6 there are some breaking changes. I would recommend you to go through the compatibility check.
- Could You please review the .NET 6 Compatibility Guide.
- Check the version of the .NET SDK that you're using. You can do this by running the following command in a command prompt or terminal window:
dotnet --version
This command will display the version of the .NET SDK that is currently installed on your system. If the version is older than 5.0, you should update it to the latest version.
- You also need to run the command
dotnet –list-runtimes
and check the installed dotnet runtimes. - Update Visual Studio to the latest version. Visual Studio includes many tools and features that are designed to work with .NET 6.0.
- Check the project file to ensure that it is targeting the correct version of .NET. You can do this by opening the project file in a text editor and looking for the following line:
<TargetFramework>net6.0</TargetFramework>
If this line is missing or has a different version number, you should update it to the correct version.
- If you're using a build server or continuous integration (CI) system, make sure that it is configured to use the correct version of the .NET SDK.
Hope the above suggestion helps.
On a side note, If you want assistance from Devops pipeline standpoint, You can ask the experts in the dedicated forum over here:
https://stackoverflow.com/questions/tagged/devops https://developercommunity.visualstudio.com/spaces/21/index.html
DevOps pipelines is currently not supported in the Q&A forums, the supported products are listed over here https://learn.microsoft.com/en-us/answers/products (more to be added later on).
**
Please do not forget to "Accept the answer” and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.