0

Not sure what is causing this odd behavior: Step1: I had a project, one solution , one project.

C:\Repos\CatWeather

So CatWeather.csproj and CatWeather.csproj are in this folder. Builds fine. OK. Now I right click on the solution and choose to Add A New Project, a Unit Test project. Well I do want them to be under same source control branch so I choose the location of this one to be inside the same folder enter image description here

And that's where it gets messed up. Look at what it does: enter image description here

enter image description here

This is wrong and causes build to fail. Even if I delete that extra folder, it keep building it and putting it back. Why is it doing that?

5
  • Seems like some build configuration, Maybe there something messed up in project properties? I would also try analyze *.sln file and *.csproj file to see if there are any unexpected issues (compare with the other project that is correctly set). Also, you could try recreating the project. Commented Apr 5, 2024 at 13:09
  • @MichałTurczyn compared now. Nothing out of ordinary. A good sample project the only different as that's older and .NET 6.0 but build , config, etc were the same which are both pretty much the defaults you get by wizard building the apps. Commented Apr 5, 2024 at 13:45
  • 1
    stackoverflow.com/questions/43173811/… Commented Apr 5, 2024 at 14:01
  • Does the problem happen in new project or latest Visual Studio? Commented Apr 18, 2024 at 9:28
  • @MinxinYu-MSFT yes, latest VS Professional and brand new projects. The "exclude" solution that was suggested in the link above from Hans solved the problem. Commented Apr 18, 2024 at 11:32

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.