-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Directory.Build.targets
22 lines (20 loc) · 1 KB
/
Directory.Build.targets
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<Project>
<Target Name="AddInternalsVisibleTo" BeforeTargets="BeforeCompile">
<!-- Add default suffix if there is no InternalsVisibleTo or InternalsVisibleToSuffix defined -->
<ItemGroup Condition="@(InternalsVisibleToSuffix->Count()) == 0 AND @(InternalsVisibleTo->Count()) == 0">
<InternalsVisibleToSuffix Include=".Tests" />
</ItemGroup>
<!-- Handle InternalsVisibleTo -->
<ItemGroup Condition="'@(InternalsVisibleTo->Count())' > 0">
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
<_Parameter1>%(InternalsVisibleTo.Identity)</_Parameter1>
</AssemblyAttribute>
</ItemGroup>
<!-- Handle InternalsVisibleToSuffix -->
<ItemGroup Condition="@(InternalsVisibleToSuffix->Count()) > 0">
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleTo">
<_Parameter1>$(AssemblyName)%(InternalsVisibleToSuffix.Identity)</_Parameter1>
</AssemblyAttribute>
</ItemGroup>
</Target>
</Project>