You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wanted to upgrade from 2.1.2 to current MSTest.TestAdapter and MSTest.TestFramework v3.1.1, the following code will crash the test execution:
namespaceTestiTestopenMicrosoft.VisualStudio.TestTools.UnitTesting[<TestClass>]type``This is a test type``()=[<TestMethod>]member_.``This is a test``()=
Assert.IsTrue(true);
The output of that code is following:
Building Test Projects
========== Starting test run ==========
An exception occurred while invoking executor 'executor://mstestadapter/v2': Object reference not set to an instance of an object.
Stack trace:
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.UnitTestRunner.ClassCleanupManager.MarkTestComplete(TestMethodInfo testMethodInfo, TestMethod testMethod, Boolean& shouldRunEndOfClassCleanup, Boolean& shouldRunEndOfAssemblyCleanup) in /_/src/Adapter/MSTest.TestAdapter/Execution/UnitTestRunner.cs:line 315
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.UnitTestRunner.RunRequiredCleanups(ITestContext testContext, TestMethodInfo testMethodInfo, TestMethod testMethod, UnitTestResult[] results) in /_/src/Adapter/MSTest.TestAdapter/Execution/UnitTestRunner.cs:line 167
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.UnitTestRunner.RunSingleTest(TestMethod testMethod, IDictionary`2 testContextProperties) in /_/src/Adapter/MSTest.TestAdapter/Execution/UnitTestRunner.cs:line 145
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.TestExecutionManager.ExecuteTestsWithTestRunner(IEnumerable`1 tests, ITestExecutionRecorder testExecutionRecorder, String source, IDictionary`2 sourceLevelParameters, UnitTestRunner testRunner) in /_/src/Adapter/MSTest.TestAdapter/Execution/TestExecutionManager.cs:line 400
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.TestExecutionManager.ExecuteTestsInSource(IEnumerable`1 tests, IRunContext runContext, IFrameworkHandle frameworkHandle, String source, Boolean isDeploymentDone) in /_/src/Adapter/MSTest.TestAdapter/Execution/TestExecutionManager.cs:line 352
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.TestExecutionManager.ExecuteTests(IEnumerable`1 tests, IRunContext runContext, IFrameworkHandle frameworkHandle, Boolean isDeploymentDone) in /_/src/Adapter/MSTest.TestAdapter/Execution/TestExecutionManager.cs:line 155
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.Execution.TestExecutionManager.RunTests(IEnumerable`1 tests, IRunContext runContext, IFrameworkHandle frameworkHandle, TestRunCancellationToken runCancellationToken) in /_/src/Adapter/MSTest.TestAdapter/Execution/TestExecutionManager.cs:line 92
at Microsoft.VisualStudio.TestPlatform.MSTest.TestAdapter.MSTestExecutor.RunTests(IEnumerable`1 tests, IRunContext runContext, IFrameworkHandle frameworkHandle) in /_/src/Adapter/MSTest.TestAdapter/MSTestExecutor.cs:line 72
at Microsoft.VisualStudio.TestPlatform.Common.ExtensionDecorators.SerialTestRunDecorator.RunTests(IEnumerable`1 tests, IRunContext runContext, IFrameworkHandle frameworkHandle) in /_/src/Microsoft.TestPlatform.Common/ExtensionDecorators/SerialTestRunDecorator.cs:line 44
at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.RunTestsWithTests.InvokeExecutor(LazyExtension`2 executor, Tuple`2 executorUri, RunContext runContext, IFrameworkHandle frameworkHandle) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Execution/RunTestsWithTests.cs:line 72
at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.BaseRunTests.RunTestInternalWithExecutors(IEnumerable`1 executorUriExtensionMap, Int64 totalTests) in /_/src/Microsoft.TestPlatform.CrossPlatEngine/Execution/BaseRunTests.cs:line 466
========== Test run finished: 0 Tests (0 Passed, 0 Failed, 0 Skipped) run in 63 ms ==========
Visual Studio 17.8.2 dotnet --info:
.NET SDK:
Version: 8.0.100
Commit: 57efcf1350
Workload version: 8.0.100-manifests.8d38d0cc
Runtime Environment:
OS Name: Windows
OS Version: 10.0.22631
OS Platform: Windows
RID: win-x64
Base Path: C:\Program Files\dotnet\sdk\8.0.100\
Steps To Reproduce
Just execute the F# code above with
MSTest.TestAdapter & MSTest.TestFramework both version 3.1.1
Microsoft.NET.Test.Sdk version 17.8.0
Additional context
Changing the code: type ``This is a test type`` () = to: type ``ThisIsATest`` () = will fix the code.
Probably are whitespaces not allowed here but in F# it's a valid type name.
I found this related issue: #941
We will most likely be releasing 3.2.X in the upcoming weeks so I will hold closing this issue to see if we need to do some backport and release a 3.1.2 now.
We had a bit of delay but we are on track with final release for around 15th (maybe a bit sooner) so I'll move forward and close this issue. Feel free to comment/reopen if the ETA is too far away.
I wanted to upgrade from 2.1.2 to current MSTest.TestAdapter and MSTest.TestFramework v3.1.1, the following code will crash the test execution:
The output of that code is following:
Visual Studio 17.8.2
dotnet --info
:Steps To Reproduce
Just execute the F# code above with
MSTest.TestAdapter & MSTest.TestFramework both version 3.1.1
Microsoft.NET.Test.Sdk version 17.8.0
Additional context
Changing the code:
type ``This is a test type`` () =
to:type ``ThisIsATest`` () =
will fix the code.Probably are whitespaces not allowed here but in F# it's a valid type name.
I found this related issue: #941
AB#1925775
The text was updated successfully, but these errors were encountered: