I have a C # / ASP.NET site with some code files (* .cs) in the App_Code directory. I would like to test them using NUnit. I wrote a test file with the corresponding [TestFixture] and [Test] annotations and posted it here: App_Code / Test / TestClassName.cs.
I download the NUnit GUI to run it, but it wants me to select the .exe or .dll file. There is not one in the bin folder of my project. My project starts and builds successfully, and that’s all, but still not an exe or dll file. How can I get NUnit Gui to just run a test in this class?
, .
, , Business.UnitTest(, nUnit, , ). -, App_Code, "". Business.UnitTest -. nUnit ( , nUnit -, , 100%).
-, - -. , , .
.NET Website , , . , , , , NUnit .exe .dll .
.exe
.dll
- - ; , -. -, , -. , , (.dll) (.exe). NUnit , .
, ; - , . , . - , .
, - , , . NUnit . - , NUnit .
. - , InternalsVisibleToAttribute, , "" . , Assembly.info "" .
InternalsVisibleToAttribute
"" .
, (assembly.dll);
Open TestsProjectAssembly.dllNUnit from your GUI, making sure that you are browsing the desired folder;
TestsProjectAssembly.dll
You may also want the NUnit GUI to reload your assembly each time you run tests (there is an option for this in the options properties);
Run the tests.
Make absolutely sure that your path or folder for viewing is the one in which your test project is created.
Source: https://habr.com/ru/post/1746604/More articles:How to templatize a container type in a function declaration? - c ++Django Form and Ownership - djangoTranslator with a single-mode virtual machine - you can evaluate all the math. expressions? - stackTkinter integration with glib mainloop - pythonGoogle App Engine, task queues - pythonWinForms Mouse Capture - c #https://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1746606/cannot-handle-redirect-from-httphttps-protocols-to-other-dissimilar-ones&usg=ALkJrhidmGxc1uO3L5Ut4m96SgLfv6wkVwCannot get HTML code through HttpWebRequest - c #https://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1746608/proper-exceptions-to-use-for-nulls&usg=ALkJrhgv6NNtCasVCDWlT3UFsunRN2O7lQhow to pass dynamic data to decorators - pythonAll Articles