How do I run NUnit in debug mode from Visual Studio?

后端 未结 19 1374
闹比i
闹比i 2020-11-30 17:59

I\'ve recently been building a test framework for a bit of C# I\'ve been working on. I have NUnit set up and a new project within my workspace to test the component. All wor

19条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-30 18:09

    For me solution was to adapt nunit configuration file. To use nunit with 4.5-.Net framework and x64 build option, I had to add one line to startup tag (supported runtime-version).

    
            
            
    
    

    Afterwards, I could start by right-click on the Testproject Debug -> Start new instance. Before, I needed to again manually attach the project to the process.

    My Debug properties were, C:\Program Files (x86)\NUnit 2.6.4\bin\nunit.exe with argument of the location of the .dll to be tested.

    More information: nunit for testing with .NET 4.0

提交回复
热议问题