Problem with Unit Testing Sharepoint RRS feed

  • Question

  • Dear Community,

    I wanted to start using Test Projects for Sharepoint as of now, but I have a Problem configuring the Test Project for it.

    My TestMethod is pretty simple:

            public void CreateProjectPage()
                SPWeb web = SPContext.Current.Web;
                SPWeb projectPortal = web.Webs.Add("projektportal", "Projektportal", null, 1031, web.Site.GetWebTemplates(1031)["STS#1"], false, false);

    As you can see, I configured HostType and Url ToTest. But when I hit "Run Test", it always fails with the following errormessage:

    "The host type 'ASP.NET' cannot be loaded for the following reason: The key 'ASP.NET' cannot cannot be found."

    Can anyone tell me, what I missed out when I configured the test?
    Thanks in advance,


    Monday, May 2, 2011 1:23 PM


All replies