Test projects will not load in VS08

When I try to download the solution, I get the following error:

The project file [file path] cannot be opened. The project type is not supported by this setting.

After double clicking β€œOK”, my solution loads perfectly, with the exception of two test projects (the link [filepath] above refers to these two test projects), which are grayed out. When I try to expand them, they show a message:

The project file could not be uploaded.

I am running VS08 Pro SP1 and .NET 3.5 SP1. Test projects were also created at Pro. This problem has two strange components:

  • When trying to "restore" the VS installation, he says the tests are already installed. This can be seen from the "Test" option in the menu bar at the top of the VS.
  • If I wanted to create a new test project, VS gives me the opportunity in the create dialog.

I saw this question and tried to execute the answer through the VS command prompt, but not a cube.

Does anyone know what is going on here?

+4
source share
6 answers

Now you can edit the project file so that it loads in versions of VS that do not support testing:

http://www.ademiller.com/blogs/tech/2007/10/gotchas-mstest-test-projects-dont-load-on-vs-pro/

  • Right-click on the project and select "Change ..." to open the project file as XML.
  • List item
  • Delete the list line that looks like this:

    <ProjectTypeGuids> {3AC096D0-A1C2-E12C-1390-A8335801FDAB}; {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} </ProjectTypeGuids>

  • Save and close the XML file. Right-click on the project and reload it.

You need to remove the project GUID that pass VS is a test project and is not actually supported in your version of VS. This will allow the project to load, but obviously, if you do not have testing functions, MSTEST will not be available to run the tests.

If the VS version supports testing, check and see if this line is in the project file.

+2
source

As SLaks already asked, can you create new test projects on a computer with problems? If you can create new ones without any problems, try using diff between a good project file and a bad one. This may show you if you are using two different versions - probably bad projects have something that is incompatible with your installation.

+1
source

You are probably using the express version of Visual Studio, which does not include unit testing.

EDIT . Since you have the Test menu, you obviously are not using Express Edition. I keep this answer for reference.

0
source

This may be a problem with a specific test project. What is this test project?

If you create a new test project, do you get any errors?

What version of Visual Studio are you using?

Some types of test projects are supported only by Team Suite.

0
source

What is a test project? perhaps you are opening a test project for Team Edition on the VS2008 Pro.

0
source

Created or edited a test project when evaluating ReSharper, expired license eval? There may be some residual β€œsubstance” that ReSharper places in the test project file.

I would try the SLaks / Pedro solution to create a new test project to see if something might have broken in VS, or if your project file was corrupted.

0
source

All Articles