Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fail to debug tests in vs2017 when "use the new test execution framework" is True #126

Closed
aey76 opened this issue Apr 4, 2017 · 6 comments
Assignees
Labels
Milestone

Comments

@aey76
Copy link

aey76 commented Apr 4, 2017

This is the output when trying to debug tests when "use the new test execution framework" is True.

GTA 0.9.1
VS2017 pro build 26228.12

------ Run test started ------
Google Test Adapter: Test execution starting...
ERROR: Couldn't find the msdia.dll to parse *.pdb files. You will not get any source locations for your tests.
Warning: Could not find source location for test aaa.bbb_1
Warning: Could not find source location for test aaa.bbb_2
Found 2 tests in executable C:\Users\w7pro\Documents\Visual Studio 2017\Projects\ProjectDir\Debug\ConsoleApplication1_Tests.exe
ERROR: Exception while running tests: System.IO.FileNotFoundException: Could not load file or assembly 'EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
File name: 'EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
at GoogleTestAdapter.TestAdapter.Framework.VsDebuggerAttacher..ctor(ILogger logger, Int32 processId)
at GoogleTestAdapter.TestAdapter.TestExecutor.DoRunTests(IEnumerable1 allTestCasesInExecutables, ICollection1 testCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle)
at GoogleTestAdapter.TestAdapter.TestExecutor.TryRunTests(IEnumerable1 vsTestCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle) at GoogleTestAdapter.TestAdapter.TestExecutor.RunTests(IEnumerable1 vsTestCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle)

=== Pre-bind state information ===
LOG: DisplayName = EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
(Fully-specified)
LOG: Appbase = file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/
LOG: Initial PrivatePath = NULL
Calling assembly : GoogleTestAdapter.TestAdapter, Version=0.9.1.721, Culture=neutral, PublicKeyToken=028d073f99e04687.
===
LOG: This bind starts in LoadFrom load context.
WRN: Native image will not be probed in LoadFrom context. Native image will only be probed in default load context, like with Assembly.Load().
LOG: Using application configuration file: C:\PROGRAM FILES\MICROSOFT VISUAL STUDIO\2017\PROFESSIONAL\COMMON7\IDE\COMMONEXTENSIONS\MICROSOFT\TESTWINDOW\vstest.executionengine.exe.Config
LOG: Using host configuration file:
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Post-policy reference: EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE/EnvDTE.EXE.

ERROR:
================
The following errors and warnings occured during test execution (enable debug mode for more information):
ERROR: Couldn't find the msdia.dll to parse *.pdb files. You will not get any source locations for your tests.
Warning: Could not find source location for test aaa.bbb_1
Warning: Could not find source location for test aaa.bbb_2
ERROR: Exception while running tests: System.IO.FileNotFoundException: Could not load file or assembly 'EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
File name: 'EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
at GoogleTestAdapter.TestAdapter.Framework.VsDebuggerAttacher..ctor(ILogger logger, Int32 processId)
at GoogleTestAdapter.TestAdapter.TestExecutor.DoRunTests(IEnumerable1 allTestCasesInExecutables, ICollection1 testCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle)
at GoogleTestAdapter.TestAdapter.TestExecutor.TryRunTests(IEnumerable1 vsTestCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle) at GoogleTestAdapter.TestAdapter.TestExecutor.RunTests(IEnumerable1 vsTestCasesToRun, IRunContext runContext, IFrameworkHandle frameworkHandle)

=== Pre-bind state information ===
LOG: DisplayName = EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
(Fully-specified)
LOG: Appbase = file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/
LOG: Initial PrivatePath = NULL
Calling assembly : GoogleTestAdapter.TestAdapter, Version=0.9.1.721, Culture=neutral, PublicKeyToken=028d073f99e04687.
===
LOG: This bind starts in LoadFrom load context.
WRN: Native image will not be probed in LoadFrom context. Native image will only be probed in default load context, like with Assembly.Load().
LOG: Using application configuration file: C:\PROGRAM FILES\MICROSOFT VISUAL STUDIO\2017\PROFESSIONAL\COMMON7\IDE\COMMONEXTENSIONS\MICROSOFT\TESTWINDOW\vstest.executionengine.exe.Config
LOG: Using host configuration file:
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Post-policy reference: EnvDTE, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/EnvDTE/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/PROGRAM FILES/MICROSOFT VISUAL STUDIO/2017/PROFESSIONAL/COMMON7/IDE/COMMONEXTENSIONS/MICROSOFT/TESTWINDOW/Extensions/EnvDTE/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE/EnvDTE.DLL.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE.EXE.
LOG: Attempting download of new URL file:///C:/USERS/W7PRO/APPDATA/LOCAL/MICROSOFT/VISUALSTUDIO/15.0_51E7F315/EXTENSIONS/XP35DA1P.2FR/EnvDTE/EnvDTE.EXE.
========== Run test finished: 0 run (0:00:05.1699218) ==========

@csoltenborn
Copy link
Owner

Can you please check whether the registry patch I attached to #124 fixes also this issue by any chance?

@aey76
Copy link
Author

aey76 commented Apr 9, 2017

The patch from #124 didn't fix this problem, However it did fix for me the missing msdia.dll problem.

@csoltenborn
Copy link
Owner

I can confirm that I see the same problem on VS2017 (isolated instance - no previous installations of VS2015 or such)...

@jgefele
Copy link
Collaborator

jgefele commented Apr 13, 2017

@csoltenborn
Copy link
Owner

@NinjaCoder Would you mind to give this build a try?

@aey76
Copy link
Author

aey76 commented Apr 22, 2017

@csoltenborn YES !!! I checked and the debug problem solved in this build.

csoltenborn added a commit that referenced this issue Apr 23, 2017
…d; debugging via NuGet-installed adapter is denied (#124, #126)
csoltenborn added a commit that referenced this issue Apr 23, 2017
csoltenborn added a commit that referenced this issue May 2, 2017
…ound_in_isolated_VS2017_instance

Dependencies not found in isolated vs2017 instance (#124, #126)
@csoltenborn csoltenborn self-assigned this May 2, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants