Here is my Solution files structure (folders are prefixed by +
):
+FooProject
FooProject.sln
+Tests
+BarTests
BarTests.csproj
Now I want to move the BarTests project to a new subfolder UnitTests
:
+FooProject
FooProject.sln
+Tests
+UnitTests
+BarTests
BarTests.csproj
I tried the following ways but to no avail:
- If I add a New Solution Folder,
UnitTests
, in Visual Studio, and move theBarTests
toUnitTests
folder in Visual Studio, then no new folder is created on disk, and no changes to the solution file are made, hence can't propagate this change in the source control. - I create the
UnitTests
folder directly on disk (using File Explorer or Command Line), move theBarTests
toUnitTests
, and then manually update the solution file to reflect this change in the path. Now the problem is in Visual Studio, I still see theBarTests
project under the 'Tests' folder and not theUnitTests
folder.
I tried the second approach even after closing VS and deleting the .vs
folder but still the same behavior.
What am I missing here?