Bug 41117 - [Test Recorder for VS] FileLoadException when opening UITest project
Summary: [Test Recorder for VS] FileLoadException when opening UITest project
Status: RESOLVED FIXED
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Test Cloud ()
Version: 4.1.0 (C7)
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: john
URL:
Depends on:
Blocks:
 
Reported: 2016-05-16 20:12 UTC by Joe Manke
Modified: 2016-12-23 16:58 UTC (History)
4 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Joe Manke 2016-05-16 20:12:40 UTC
Upon opening a file in UITest project, an error dialog comes up with the following message: 
"An exception has been encountered. This may be caused by an extension.

You can get more information by examining the file 'C\Users\{my username}\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml'."

In ActivityLog.xml, the following entry is recorded several times:

<entry>
    <record>863</record>
    <time>2016/05/16 19:49:21.209</time>
    <type>Error</type>
    <source>Editor or Editor Extension</source>
    <description>System.IO.FileLoadException: Could not load file or assembly &apos;Microsoft.CodeAnalysis, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&apos; or one of its dependencies. The located assembly&apos;s manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)&#x000D;&#x000A;File name: &apos;Microsoft.CodeAnalysis, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&apos; ---&gt; System.IO.FileLoadException: Could not load file or assembly &apos;Microsoft.CodeAnalysis, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&apos; or one of its dependencies. The located assembly&apos;s manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)&#x000D;&#x000A;File name: &apos;Microsoft.CodeAnalysis, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&apos;&#x000D;&#x000A;  
	at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark&amp; stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)&#x000D;&#x000A;  
	at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark&amp; stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)&#x000D;&#x000A;  
	at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark&amp; stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)&#x000D;&#x000A;  
	at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark&amp; stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)&#x000D;&#x000A;  
	at System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark&amp; stackMark, Boolean forIntrospection)&#x000D;&#x000A;  
	at System.Reflection.Assembly.Load(String assemblyString)&#x000D;&#x000A;  
	at Microsoft.VisualStudio.Design.VSTypeResolutionService.System.ComponentModel.Design.ITypeResolutionService.GetAssembly(AssemblyName name, Boolean throwOnError)&#x000D;&#x000A;  
	at Microsoft.VisualStudio.Design.VSTypeResolutionService.System.ComponentModel.Design.ITypeResolutionService.GetAssembly(AssemblyName name)&#x000D;&#x000A;  
	at Microsoft.VisualStudio.Design.VSDynamicTypeService.OnAssemblyResolve(Object sender, ResolveEventArgs e)&#x000D;&#x000A;  
	at System.AppDomain.OnAssemblyResolveEvent(RuntimeAssembly assembly, String assemblyFullName)&#x000D;&#x000A;&#x000D;&#x000A;WRN: Assembly binding logging is turned OFF.&#x000D;&#x000A;To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.&#x000D;&#x000A;Note: There is some performance penalty associated with assembly bind failure logging.&#x000D;&#x000A;To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].&#x000D;&#x000A;&#x000D;&#x000A;  
	at Xamarin.TestRecorder.VSIX.ViewModels.TestRecorderMarginViewModel.UpdateCursorGlyph()&#x000D;&#x000A;  
	at Xamarin.TestRecorder.VSIX.ViewModels.TestRecorderMarginViewModel.Update() in C:\Users\Xamarin\Documents\GitHub\test-recorder\Xamarin.TestRecorder.VSIX\ViewModels\TestRecorderMarginViewModel.cs:line 41&#x000D;&#x000A;  
	at Xamarin.TestRecorder.VSIX.TestRecorderMargin..ctor(IWpfTextView textView) in C:\Users\Xamarin\Documents\GitHub\test-recorder\Xamarin.TestRecorder.VSIX\TestRecorderMargin.cs:line 34&#x000D;&#x000A;  
	at Xamarin.TestRecorder.VSIX.TestRecorderMarginFactory.CreateMargin(IWpfTextViewHost wpfTextViewHost, IWpfTextViewMargin marginContainer) in C:\Users\Xamarin\Documents\GitHub\test-recorder\Xamarin.TestRecorder.VSIX\TestRecorderMarginFactory.cs:line 86&#x000D;&#x000A;  
	at Microsoft.VisualStudio.Text.Utilities.ContainerMargin.&lt;AddMargins&gt;b__25_1(IWpfTextViewMarginProvider mp)&#x000D;&#x000A;  
	at Microsoft.VisualStudio.Text.Utilities.GuardedOperations.InstantiateExtension[TExtension,TMetadata,TExtensionInstance](Object errorSource, Lazy`2 provider, Func`2 getter)&#x000D;&#x000A;&#x000D;&#x000A;
	</description>
 </entry>

I am able to manually write and run UI Tests, but the "New Test Recording" icon does not appear in the editor as described in the Test Recorder for Visual Studio guide. 

OS version: Windows 8.1 Enterprise
VS version: Enterprise 2015, version 14.0.24720.00 Update 1
Xamarin version: 4.1.0.462
Test Recorder version: 0.2.6
Comment 2 Joe Manke 2016-05-24 14:48:08 UTC
After updating Visual Studio to Update 2 (version 14.0.25123.00) the Test Recorder is now working correctly.
Comment 3 Juan Marcelo Tondato 2016-12-23 14:41:37 UTC
Moving to cycle10 to provide a proper solution
Comment 4 Jose Gallardo 2016-12-23 16:58:27 UTC
Actually, as per comment 2, this issue has been fixed.
Marking it accordingly.
Thanks