0

I'm currently using NCrunch 1.48.0.5 in Visual Studio 2010.

Every time I open a solution I find that NCrunch is disabled. How can I open a solution and have NCrunch enabled by default?

Ben Smith
  • 19,589
  • 6
  • 65
  • 93
  • "Questions about general computing hardware and software are off-topic for Stack Overflow unless they directly involve tools used primarily for programming." - To whoever downvoted this question, this does involve a tool (NCrunch) primarily used for programming! – Ben Smith Nov 20 '14 at 12:11

2 Answers2

2

By default, NCrunch will always start as disabled for a solution before it is explicitly turned on from the top menu.

You can toggle Ncrunch on and off from the by selecting Enable from the NCrunch Visual Studio menu.

There is also a global configuration file that has many config settings that you can use.

ncrunch documentation

SoftwareCarpenter
  • 3,835
  • 3
  • 25
  • 37
  • Thanks for the answer @SoftwareCarpenter. Yes I know that I can toggle it on/off from within the VS menu, it's just that I'd like it to be enabled by default. Can't find an appropriate setting in the NCrunch documentation. – Ben Smith Nov 20 '14 at 12:16
  • Have you tried running the configuration wizard or selecting NCrunch->Configuration? You might want to try reinstalling. – SoftwareCarpenter Nov 20 '14 at 12:25
  • Ok, so it always starts disabled by default. Whilst this isn't the behaviour I want (once I've enabled it for a solution I want it to stay enabled!) I'll mark this as the answer (plus the global config file could come in useful!) – Ben Smith Dec 08 '14 at 17:22
  • I did find a way to force Visual Studio to run the tests on start-up. See my answer. – Ben Smith Dec 16 '14 at 15:42
0

It is possible to force NCrunch to auto-enable on start-up. You can do this by setting "AutoEnableOnStartup" to true e.g.

<SolutionConfiguration>
    <AutoEnableOnStartup>true</AutoEnableOnStartup>
    ...
</SolutionConfiguration>

within the NCRUNCHSOLUTION file, which is found in the same directory as the solution file e.g.

YourSoultion.ncrunchsolution

More information can be found in the documentation here

Ben Smith
  • 19,589
  • 6
  • 65
  • 93
  • Glad you were able to find your solution. Is this a setting you can set in the global configuration file as well? Just curious but it seems setting per solution is better for some. – SoftwareCarpenter Dec 16 '14 at 19:24
  • 1
    Fyi... You can use project configuration file for even more granular control - http://www.ncrunch.net/documentation/reference_project-configuration_overview – SoftwareCarpenter Dec 16 '14 at 19:28
  • Thanks for the feedback @SoftwareCarpenter. I felt bad re-assigning the answer, but your answer is still very useful and you've got upvotes too. Yes, you can configure global, solution and project properties. I'm glad I found this setting as it was driving me mad having to re-configure NCrunch every time the solution was loaded! – Ben Smith Dec 16 '14 at 23:25
  • The answer is more specific, so no big deal. Good luck. – SoftwareCarpenter Dec 16 '14 at 23:27