Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error getting to Test Window in VS 2012 RC

I have been using the customer preview of Visual Studio 2012 up until day before yesterday when the Release Candidate became available. After I installed the Release Candidate, I can't get to the Test Window (Test / Windows / Test Explorer).

I get the following lengthy error which I've copied manually here. (Since this is my first question, I couldn't post the picture, and the screen would not allow me to copy the text to the clipboard. Hopefully there are no typos.)

The composition produced a single composition error. The root cause is provided below.  Review the CompositionException.Errors property for more detailed information.

1) Value cannot be null.
Parameter name: testPlatform

Resulting in: An exception occurred while trying to create an instance of type 'Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory'.

Resulting in: Cannot activate part
'Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory'.
Element: Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory -->
Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory --> CachedAssemblyCatalog

Resulting in: Cannot get export
Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory
(ContractName="Microsoft.VisualStudio.TestWindow.Model.RequestConfigurationFactory")' from part
'Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory'.
Element:
Microsoft.VisualStudio.TestWindow.Model.ReqeustConfigurationFactory
(ContractName="Microsoft.VisualStudio.TestWindow.Model.RequestConfigurationFactory") --> CachedAssemblyCatalog

The error occurs regardless of whether I have opened a solution or not. A second attempt to open the window yields "Cannot create the tool window." After restarting Visual Studio, and attempting to get to the Test Window, I get the long message again.

At the time I upgraded Visual Studio to the Release Candidate, I had installed:

  • NUnit
  • SpecFlow
  • ReSharper (Beta)
  • Code Contracts -- the last thing I had installed before upgrading Visual Studio. I cannot guarantee that the test window was working after I installed this.

I have searched the web for key phrases out of the error message, but found no help.

I have also:

  • Repaired Visual Studio (which solved a problem I was having getting to the Extension Manager, but not the Test Window problem)
  • Uninstalled Visual Studio and reinstalled it
  • Uninstalled each of the Extensions/packages listed above (NUnit, SpecFlow, ReSharper, Code Contracts). Uninstalling didn't seem to help, so I have re-installed all of them, one at a time. I've also confirmed that I can run tests in the ReSharper test window.
  • Deleted the currentsettings.vssettings file from C:\Users\\Documents\Visual Studio 11\Settings, hoping it contained the problem and would be recreated correctly. I got a message that "The IDE will use your most recent settings for this session". I don't know where to find those...
  • Reset settings from the Import and Export Settings option.

None of these actions has helped.

It looks to me like a config file somewhere is missing an element for testPlatform, but I have no idea where that would be (or in what format, or what Options page entry would set it.)

Any help would GREATLY be appreciated.

like image 212
woman among men Avatar asked Jan 20 '26 12:01

woman among men


1 Answers

I didn't figure out exactly what was causing the error, but I did get it fixed. Here's what finally worked

I installed all VS 2012 one more time, plus the extensions, then looked for bits that might have been left behind by the uninstall. I found and deleted the following before reinstalling:

  • C:\Users\<my id>\Documents\Visual Studio
  • C:\Users\<my id>\AppData\Roaming\Microsoft\VisualStudio
  • C:\Users\<my id>\AppData\Local\Microsoft
  • Registry: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft

Upon re-installing Visual Studio 2012 RC, the original problem was resolved. Re-installing the extensions also worked successfully.

like image 180
woman among men Avatar answered Jan 23 '26 20:01

woman among men



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!