-
Notifications
You must be signed in to change notification settings - Fork 3
/
Directory.Build.targets
42 lines (35 loc) · 1.6 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
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<Project>
<Choose>
<When Condition=" '$(IsTestProject)' == 'true' ">
<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" />
<PackageReference Include="xunit" />
<PackageReference Include="xunit.runner.visualstudio">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="coverlet.collector">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<Using Include="Xunit" />
</ItemGroup>
</When>
<Otherwise>
<!-- not test project -->
<ItemGroup>
<InternalsVisibleTo Include="$(AssemblyName).Tests" />
</ItemGroup>
</Otherwise>
</Choose>
<ItemGroup Condition=" '$(EnableStyleCop)' == 'true' ">
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="all"
IncludeAssets="runtime; build; native; contentfiles; analyzers" />
<AdditionalFiles Include="$(MSBuildThisFileDirectory)stylecop.json">
<Link>stylecop.json</Link>
</AdditionalFiles>
</ItemGroup>
<PropertyGroup Condition="'$(Configuration)'=='Debug'">
<CodeAnalysisRuleSet>$(MSBuildThisFileDirectory)\Altinn3.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
</Project>