I have a .NET assembly written in C# which is using NUnit.
The tests in this assembly calls a C++/CLI-assembly.
The C++/CLI-assembly calls native/unmanaged C++ code.
When I try to debug a unit test using Resharper, Native debugging does not seem to be enabled in Visual Studio. This has the effect that I can not properly "step" in the native/unmanaged code in C++.
I currently use a cumbersome workaround:
1) Each test calls Debugger.Break(); the first thing it does.
2) I select to Run the unit test (not debug)
3) The Debugger.Break causes a dialog to be shown which allows me to select Visual Studio instance to perform the debugging.
4) I choose to manually select debugging type.
5) I select Native in the dialog which pops up.
6) I click OK
As mentioned, this is rather cumbersome. Anyone has a more straight-forward approach to debugging unit tests calling native code?