I am unable to run the Test Cases in Visual Studio 2022 as it throws below error:
System.InvalidOperationException: Failed to load RunSettings file: 'C:\Users\<abc>\source\repos\<someproject>\<someproject>.Application.Tests\bin\Debug\net6.0\fine-code-coverage\coverage-tool-output\<someproject>.Application.Tests-fcc-mscodecoverage-generated.runsettings'. Please check if the file exists and is valid.
at Microsoft.VisualStudio.TestWindow.Controller.RunsettingsProvider.GenerateTestRunSettings(RunSettingConfigurationInfoState infoState, String runSettingsFilePath, IUserRunSettings runsettings, IEnumerable`1 runSettingsServices, IEnumerable`1 customSettingsImporters, RequestConfiguration requestConfiguration, ITestWindowVSTelemetry telemetryService)
at Microsoft.VisualStudio.TestWindow.Core.Client.ContainerRunSettingsProvider.<GetRunAllSettingsMapAsync>d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.TestWindow.Controller.DiscoveryOperation.<GetSessionRunsettingsMapAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.TestWindow.Controller.DiscoverSelectedOperation.<ExecuteInternalAsync>d__5.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.TestWindow.Controller.Operation.<<ExecuteAsync>b__43_0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.TestWindow.Logging.ILoggerExtensions.<CallWithCatchAsync>d__11`1.MoveNext()
I have tried to update the extension as well as Visual Studio but it didn't solve the issue. Can someone please help me with this?
1 - Microsoft.Testk.Sdk
2 - xunit
3 - xunit.runner.visualstudio