ASP.NET MVC controllers initialize correctly during testing

How to get a properly initialized ASP.NET MVC controller for integration test?

My current problem is that when I try to access a controller user member, I get:

System.NotImplementedException: Method or operation not implemented.

I want Ruby on Rails to provide Functional Tests out of the box.

+3
source share
4 answers

To start Cassini from unit test

 [TestMethod()]

 [HostType("ASP.NET")]

 [UrlToTest("http://localhost:25153/WebSite1")] 

Additional MSDN Information

Kindness,

Dan

+2
source
+2

-, IIS Visual Studio. Visual Studio .

0

:

, , , BaseController GetUser() , .

0

Source: https://habr.com/ru/post/1718251/


All Articles