Skip to content

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

Closed
@aey76

Description

@aey76

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) ==========

Activity

csoltenborn

csoltenborn commented on Apr 9, 2017

@csoltenborn
Owner

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

aey76

aey76 commented on Apr 9, 2017

@aey76
Author

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

csoltenborn

csoltenborn commented on Apr 13, 2017

@csoltenborn
Owner

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

jgefele

jgefele commented on Apr 13, 2017

@jgefele
Collaborator
added this to the 0.10 milestone on Apr 18, 2017
csoltenborn

csoltenborn commented on Apr 21, 2017

@csoltenborn
Owner

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

9 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

No projects

Relationships

None yet

    Development

    No branches or pull requests

      Participants

      @csoltenborn@jgefele@aey76

      Issue actions

        fail to debug tests in vs2017 when "use the new test execution framework" is True · Issue #126 · csoltenborn/GoogleTestAdapter