I just upgraded to Resharper 4.5 and now see that all my BDDish test methods are marked as not conforming to the naming standard. My naming convention is like this:
<
If you want to follow the Microsoft style guide with your non-test code sources - Have you tried using the StyleCop for ReSharper plugin?
As recommended before: disable the internal ReSharper naming rule set or toggle the inspection settings. StyleCop (thus the StyleCop ReSharper plugin) allows inheritance over the Settings.StyleCop files in your solution folder structure. So you are able to check for valid names in the "real" sources, while the analysis of the test code is disabled.
You could use
// ReSharper disable InconsistentNaming
// ReSharper restore InconsistentNaming
around the extremities of each class. e.g
// ReSharper disable InconsistentNaming
namespace bob
{
[TestClass]
public class MyTestClass
{
[TestMethod]
public void Test_Test()
{
}
}
}
// ReSharper restore InconsistentNaming
This however will remove all naming warnings, and not just those on the Method name(s).