How to support MBUnit tests in Resharper 7

2.3k Views Asked by At

Since I upgraded to VS2012, my R#5 license was not useful anymore. After downloading the R#7.0.1 and installing I realized that MbUnit no longer had builtin support for R#7.

Since I spent some time figuring out how to get the plugin running, I will post here to save anyone else the time (And in order for myself to find it back if I need to do it again...)

2

There are 2 best solutions below

8
On

A quick glance at the gallio source code at Gallio.ResharperRunner showed me that someone allready wrote the code. I could not find any distributions over at the Gallio Build Server, so I pulled the latest R#Runner code from SVN. (I got rev 3359) and compiled the v3\src\Extensions\ReSharper\Gallio.ReSharperRunner\Gallio.ReSharperRunner70.vs2010.csproj in VS2012.

The project was changed so that it references c:\Program Files\Gallio\bin\gallio.dll, and I also changed the Gallio.ReSharperRunner70.plugin file to "Content" and PreserveNewest (Instead of do not copy)

Then I copied the following 3 files from the debug\bin folder to C:\Users\MYUSERNAME\AppData\Local\JetBrains\DotNet\vAny\Plugins:

  • Gallio.dll
  • Gallio.ReSharperRunner70.dll
  • Gallio.ReSharperRunner70.plugin

Voila - MbUnit tests can be executed in VS2012 using Resharper 7

NB: Not sure the ResharperRunner code is 100% stable - I seem to notice some glitches, but at least my tests are again appearing in R#.

I will upload the compiled files once I figure out how to attach files to a question. Hmm - couldn't figure out how to do that, so I uploaded it to my website at http://www.albrektsen.net/Gallio.ResharperRunner70.zip

0
On

And here is a compiled plugin for Resharper 7.1: http://code.google.com/p/mb-unit/issues/detail?id=900#c9