Skip to content

Commit

Permalink
Fix MSB4186 error
Browse files Browse the repository at this point in the history
Fix MSB4186 error if a project references Microsoft.AspNetCore.Mvc.Testing that is not itself an ASP.NET project, such as a helper library in a test suite.
  • Loading branch information
martincostello committed Apr 6, 2021
1 parent 4d695c3 commit b4e8230
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
</Target>

<Target Name="_AddContentRootForProjectReferences" BeforeTargets="PrepareResources" DependsOnTargets="_ResolveMvcTestProjectReferences">
<ItemGroup>
<ItemGroup Condition="'@(_ContentRootProjectReferences->Count())' != 0">
<_ManifestProjects Include="%(_ContentRootProjectReferences.FusionName)">
<ContentRoot>$([System.IO.Path]::GetDirectoryName(%(_ContentRootProjectReferences.MSBuildSourceProjectFile)))</ContentRoot>
</_ManifestProjects>
Expand Down

0 comments on commit b4e8230

Please sign in to comment.