try-convert
try-convert copied to clipboard
Unsupported Project Type (Regression of Issue#156?)
Trying to convert a .NET Framework 4.8 MSTest project using try-convert v0.9.232202. I get the following error output:
(project path redacted) is an unsupported project type. Not all project type guids are supported.
All supported project type guids:
f184b08f-c81c-45f6-a57f-5abd9991f28f
fae04ec0-301f-11d3-bf4b-00c04f79efbc
60dc8134-eba5-43b8-bcc9-bb4bc16c2548
All given project type guids:
{3AC096D0-A1C2-E12C-1390-A8335801FDAB}
{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
No projects converted.
This looks the same as issue #156. I notice that it should have added the project type guid 3AC096D0-A1C2-E12C-1390-A8335801FDAB
and yet it doesn't show up in the list of supported project type guids.
Can confirm I am now getting the same error:
[X] is an unsupported project type. Not all project type guids are supported. All supported project type guids: f184b08f-c81c-45f6-a57f-5abd9991f28f fae04ec0-301f-11d3-bf4b-00c04f79efbc 60dc8134-eba5-43b8-bcc9-bb4bc16c2548 All given project type guids: {3AC096D0-A1C2-E12C-1390-A8335801FDAB} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
I did some debugging of this and the issue is related to the new way that MS does unit tests. They no longer recommend putting in project references to the test dlls instead there are nuget packages installed.
So the logic in MSBuildHelpers.IsNETFrameworkMSTestProject fails to find any test references and reports unknown type.
The added packages are
<PackageReference Include="MSTest.TestAdapter">
<Version>2.2.10</Version>
</PackageReference>
<PackageReference Include="MSTest.TestFramework">
<Version>2.2.10</Version>
</PackageReference>
I think a work around would be to add a reference to the tests back in.