7

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

espenalb
  • 538
  • 3
  • 17

2 Answers2

11

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

espenalb
  • 538
  • 3
  • 17
  • The current runner has several issues - I have created http://code.google.com/p/mb-unit/issues/detail?id=900 over at the gallio bug-tracker. – espenalb Oct 19 '12 at 22:18
  • What version of Gallio are you running? I tried your files and also tried downloading and building the source myself with the same modifications you made, however I get the following error in ReSharper: The plugin “StandardPluginFolders” file C:\Users\ME\AppData\Local\JetBrains\DotNet\vAny\Plugins\Gallio.ReSharperRunner70.plugin could not be loaded as valid a .NET assembly. – hermiod Nov 01 '12 at 11:23
  • I am running Gallio3.4 build 11. I have just re-uploaded the plugin I am currently using to http://www.albrektsen.net/Gallio.ResharperRunner70.zip - works ok for me. NB: It is not stable - as pointed out in the MbUnit issue, but works much better than the one compiled from trunk. – espenalb Nov 05 '12 at 19:56
  • 1
    That build did the trick for me. I also realised I was still referencing the old MBUnit and Gallio DLLs. Thanks espenalb. – hermiod Nov 07 '12 at 08:43
  • Applauding your effort! Works superbly for me. – Martin Nov 08 '12 at 10:17
  • Although I'm getting alot less information than before. For example, "Expected values to be equal". In 2010/R# 6 it said one is 5 the other is 3. I have to debugger it to find out. Why is that? – Martin Nov 08 '12 at 20:25
  • I know - that really sucks. I have not looked into it - will update this issue if I make any progress. – espenalb Nov 09 '12 at 07:06
  • I installed and running works but debugging the unit test throws "Could not load file or assembly 'Gallio.ReSharperRunner71" See: http://stackoverflow.com/questions/15550540/debug-unit-tests-using-resharper-7-for-mbunit-throws-an-exception Help is much appreciated. – Barka Mar 21 '13 at 15:27
4

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

espenalb
  • 538
  • 3
  • 17