Sysprogs forums › Forums › VisualGDB › TestContainer not found
- This topic has 7 replies, 2 voices, and was last updated 5 years, 9 months ago by support.
-
AuthorPosts
-
January 17, 2019 at 14:51 #23513Paul-AParticipant
Hello,
I have created an embedded project for unit tests for STM32. I use the wizard, and the project compiles. But if I try to launch the tests I have the following result:
[17/01/2019 14:36:09 Informational] ------ Run test started ------ [17/01/2019 14:36:10 Informational] Running tests from C:\EmbeddedProject1\EmbeddedProject2\EmbeddedProject2-Release.vgdbsettings... [17/01/2019 14:36:15 Error] System.InvalidOperationException: The following TestContainer was not found 'C:\EmbeddedProject1\EmbeddedProject2\EmbeddedProject2-Release.vgdbsettings' at Microsoft.VisualStudio.TestWindow.Controller.TestContainerProvider.<GetTestContainerAsync>d__61.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryDataStorage.<AccumulateTestCaseInternal>d__23.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryUnitTestWriter.<WriteTestCaseInternal>d__13.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryUnitTestWriter.<WriteTestResultsInternal>d__19.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.UnitTestWriter.<WriteTestResults>d__46.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.TestRunRequest.<TestRunStatsChange>d__49.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.TestRunRequest.<>c__DisplayClass50_0.<<OnTestRunStatsChange>b__0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.UnitTestStorage.<ExecuteWhileOpen>d__30.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.Request.<ExecuteWhileStorageIsOpen>d__100.MoveNext() [17/01/2019 14:36:20 Informational] Test container loaded (lookup: 13 msec, fetch: 0 msec, symbol list: 55 msec) [17/01/2019 14:36:20 Informational] ========== Run test finished: 0 run (0:00:10,7576961) ==========
I didn’t modify source code, so it should launch the 3 default tests.
I use VisualGDB 5.4 with visual studio 2017 15.9.5
- This topic was modified 5 years, 10 months ago by support. Reason: formatting
January 17, 2019 at 20:35 #23520supportKeymasterHi,
Could you have accidentally deleted the .vgdbsettings file mentioned in the error? Please try creating a new test project from scratch. Are you able to run the tests from it? Does switching the new project to the Release configuration (you would need to build the project after switching the configuration) result in an error again?
January 18, 2019 at 08:57 #23526Paul-AParticipantThe files are not deleted, and I have the same problem in debug and release configuration. As I said, the project is already “from scratch” because I just created an embedded project with the wizard. The only thing which is not as default parameters is “shared files”, “ARM toolchain”, “Embedded BSPs” and “Test Framewaork” there are not saved in C:\[…]\AppData\Local\VisualGDB\
Is it the problem ? I need to set another path, because I share these files through git.
January 19, 2019 at 06:18 #23542supportKeymasterThe test framework location should not be related. It looks like something on the VS side fails to load the test container.
Please try setting the following registry value (DWORD):
HKCU\SOFTWARE\Sysprogs\VisualGDB\Settings\ExtraVerboseTestExecutorLogging = 1
Then restart Visual Studio and try running the tests and then debugging the tests. Then share the Test Output and the output from View->Other Windows->VisualGDB Diagonstics Console.
January 21, 2019 at 11:20 #23544Paul-AParticipantOk here is the log:
VisualGDB build 5.4.100.2737 Startup initialization took 563 msec RenameHighlightSmartTaggerProvider: creating tagger for BuildOutput... Project enumeration for test discovery failed: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) ------------------ System.NotImplementedException ------------------ System.NotImplementedException: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) at EnvDTE.Project.get_FullName() at zf.f5..ctor(zf b, Project a) at zf.z1.x2(Project a) at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext() at v51.get_TestContainers() RenameHighlightSmartTaggerProvider: creating tagger for TestsOutput... Project enumeration for test discovery failed: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) ------------------ System.NotImplementedException ------------------ System.NotImplementedException: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) at EnvDTE.Project.get_FullName() at zf.f5..ctor(zf b, Project a) at zf.z1.x2(Project a) at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext() at v51.get_TestContainers() Project enumeration for test discovery failed: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) ------------------ System.NotImplementedException ------------------ System.NotImplementedException: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) at EnvDTE.Project.get_FullName() at zf.f5..ctor(zf b, Project a) at zf.z1.x2(Project a) at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext() at v51.get_TestContainers() Project enumeration for test discovery failed: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) ------------------ System.NotImplementedException ------------------ System.NotImplementedException: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL)) at EnvDTE.Project.get_FullName() at zf.f5..ctor(zf b, Project a) at zf.z1.x2(Project a) at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext() at v51.get_TestContainers()
January 21, 2019 at 23:40 #23550supportKeymasterThanks for the log. Looks like Visual Studio throws an error while VisualGDB tries to enumerate the test containers. It might not be related to the original problem, but either way we have added better handling for this here: http://sysprogs.com/files/tmp/VisualGDB-5.4.100.2757.msi
Unfortunately, you did not include the updated log from the regular View->Output->Tests (the registry setting would increase its verbosity), so there might be other issues preventing the tests from starting. If the updated build doesn’t solve the problem, please attach both VisualGDB Diagnostics log and the regular test output log.
Please also consider repairing your VS installation – the problem might be caused by missing components of the VS side.
January 22, 2019 at 13:35 #23551Paul-AParticipantI have repaired VS just in case, and I have installed the MSI file you gave, this is the output console:
[22/01/2019 13:18:36 Informational] ========== Discover test finished: 3 found (0:00:02,5226614) ========== [22/01/2019 13:18:36 Informational] ------ Run test started ------ [22/01/2019 13:18:37 Informational] RunTests() - entry [22/01/2019 13:18:37 Informational] Running tests from C:\EmbeddedProject1\EmbeddedProject3\EmbeddedProject3-Release.vgdbsettings... [22/01/2019 13:18:37 Informational] Initializing test container from C:\EmbeddedProject1\EmbeddedProject3\EmbeddedProject3-Release.vgdbsettings... [22/01/2019 13:18:38 Informational] Discovering tests... [22/01/2019 13:18:38 Informational] Running test discoverer... [22/01/2019 13:18:38 Informational] Discovered 0 tests using the advanced discoverer [22/01/2019 13:18:38 Informational] Discovered 3 tests using regular discoverers [22/01/2019 13:18:38 Informational] Discovered 3 tests. [22/01/2019 13:18:38 Informational] Remote communication pipe absent. [22/01/2019 13:18:38 Informational] Starting test result streaming.... [22/01/2019 13:18:40 Informational] ReportTestResults(C:\EmbeddedProject1\EmbeddedProject3\EmbeddedProject3-Release.vgdbsettings) [22/01/2019 13:18:40 Informational] Waiting for test packet... [22/01/2019 13:18:41 Informational] Got VisualGDB.TestEngine.TestReportingProtocolReader+ReferenceAddressPacket [22/01/2019 13:18:41 Informational] Finished processing VisualGDB.TestEngine.TestReportingProtocolReader+ReferenceAddressPacket [22/01/2019 13:18:41 Informational] Waiting for test packet... [22/01/2019 13:18:41 Informational] Got VisualGDB.TestEngine.TestReportingProtocolReader+TestStartingPacket [22/01/2019 13:18:41 Informational] Processing test start packet... [22/01/2019 13:18:42 Informational] Reporting test start: e48f9a1d-958b-466d-ac7d-707af163d93b [22/01/2019 13:18:42 Informational] Finished processing VisualGDB.TestEngine.TestReportingProtocolReader+TestStartingPacket [22/01/2019 13:18:42 Informational] Waiting for test packet... [22/01/2019 13:18:42 Informational] Got VisualGDB.TestEngine.TestReportingProtocolReader+TestFailedPacket [22/01/2019 13:18:42 Informational] Finished processing VisualGDB.TestEngine.TestReportingProtocolReader+TestFailedPacket [22/01/2019 13:18:42 Informational] Waiting for test packet... [22/01/2019 13:18:42 Error] System.InvalidOperationException: The following TestContainer was not found 'C:\EmbeddedProject1\EmbeddedProject3\EmbeddedProject3-Release.vgdbsettings' at Microsoft.VisualStudio.TestWindow.Controller.TestContainerProvider.<GetTestContainerAsync>d__61.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryDataStorage.<AccumulateTestCaseInternal>d__23.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryUnitTestWriter.<WriteTestCaseInternal>d__13.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at Microsoft.VisualStudio.TestWindow.Data.InMemory.InMemoryUnitTestWriter.<WriteTestResultsInternal>d__19.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.UnitTestWriter.<WriteTestResults>d__46.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.TestRunRequest.<TestRunStatsChange>d__49.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.TestRunRequest.<>c__DisplayClass50_0.<<OnTestRunStatsChange>b__0>d.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Data.UnitTestStorage.<ExecuteWhileOpen>d__30.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Microsoft.VisualStudio.TestWindow.Controller.Request.<ExecuteWhileStorageIsOpen>d__100.MoveNext() [22/01/2019 13:18:52 Warning] The request has taken more than 10 seconds to respond, aborting it.
For information, I have created a new solution with a new project, and it works, I don’t know where the difference could be.
January 22, 2019 at 22:47 #23554supportKeymasterBased on the log file, the test session actually starts, so the “missing test container” error doesn’t make sense. If creating a new project after reinstalling VS helped, most likely some global setting was corrupt and it affected some other setting in the project. If a newly created project works, please consider making a backup of it in case you run into the same problem again.
You could also try deleting the .vs folder in the broken project (also the Debug/Release, VisualGDBCache, etc) to see if that fixes the problem, but it may not be worth the effort if newly created projects work.
-
AuthorPosts
- You must be logged in to reply to this topic.