Welcome to mirror list, hosted at ThFree Co, Russian Federation.

Directory.Build.props « tests « src - github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 70f887117c172204f1868ebc39f971acfd6744a9 (plain)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <Import Project="$(MSBuildThisFileDirectory)\Common\dir.sdkbuild.props" Condition="'$(UsingMicrosoftNETSdk)' == 'true'"  />
  <Import Project="$(MSBuildThisFileDirectory)\Common\dir.common.props" Condition="'$(UsingMicrosoftNETSdk)' != 'true'"  />

  <PropertyGroup>
    <RunningOnUnix Condition="('$(RunningOnUnix)' == '') And ('$(MSBuildRuntimeType)' == 'Core') And ('$(OS)'!='Windows_NT')">true</RunningOnUnix>
  </PropertyGroup>

  <!-- Common repo directories -->
  <PropertyGroup>
    <TestProjectDir>$(MSBuildThisFileDirectory)</TestProjectDir>
    <TestSourceDir>$([MSBuild]::NormalizePath('$(RepoRoot)/src/tests/'))</TestSourceDir>
  </PropertyGroup>

  <PropertyGroup>
    <AltJitArch>$(__AltJitArch)</AltJitArch>
  </PropertyGroup>

  <!-- Output paths -->
  <PropertyGroup>
    <!-- When not using the SDK, we want to set this property here so
         that BuildVersionFile gets the correct value. -->
    <BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)' == '' Or '$(UsingMicrosoftNETSdk)' != 'true'">$(ArtifactsDir)obj\</BaseIntermediateOutputPath>
    <IntermediateOutputPath Condition="'$(IntermediateOutputPath)' == ''">$(BaseIntermediateOutputPath)\$(TargetOS).$(TargetArchitecture).$(Configuration)</IntermediateOutputPath>
    <OutputPath Condition="'$(OutputPath)' == ''">$(BaseIntermediateOutputPath)\coreclr\$(TargetOS).$(TargetArchitecture).$(Configuration)</OutputPath>
  </PropertyGroup>

    <!-- Targeting Package paths -->
  <PropertyGroup>
    <TargetingPackPath Condition="'$(BaseTargetingPackPath)' == ''">$(ArtifactsDir)TargetingPack\</TargetingPackPath>
  </PropertyGroup>

  <PropertyGroup Condition="'$(BuildAllProjects)'=='true'">
    <!-- When we do a traversal build we get all packages up front, don't restore them again -->
    <RestorePackages>false</RestorePackages>
  </PropertyGroup>

  <!-- Which tests shall we build? Default: Priority 0 tests.
    At the command-line, the user can specify /p:CLRTestPriorityToBuild=666 (for example), and
    all tests with CLRTestPriority 666,..., 1 AND 0 will build.

    Consequently, specifying CLRTestPriorityToBuild=1 will build all tests with CLRTestPriority 1 and 0.

    CLRTestPriority = 0 will build only priority 0 cases.

    In other words, the CLRTestPriority cases of 0 are *essential* testcases. The higher the value,
    the less priority we give them.
   -->
  <PropertyGroup>
    <CLRTestPriorityToBuild>0</CLRTestPriorityToBuild>
  </PropertyGroup>

  <!-- Which tests can we build? Default: Build managed tests for this target.
    At the command-line, the user can specify:
    +  /p:CLRTestBuildAllTargets=allTargets    Build managed tests for all target platforms.
   -->
  <PropertyGroup>
    <CLRTestBuildAllTargets></CLRTestBuildAllTargets>
  </PropertyGroup>

  <!-- Language settings -->
  <PropertyGroup>
    <RunAnalyzers>false</RunAnalyzers>
  </PropertyGroup>

  <!-- Setup Default symbol and optimization for Configuration -->
  <PropertyGroup Condition="'$(Configuration)' == 'Debug'">
    <Optimize Condition="'$(Optimize)' == ''">false</Optimize>
    <DebugType Condition="'$(DebugType)' == ''">full</DebugType>
    <DefineConstants>$(DefineConstants);DEBUG;TRACE;XUNIT_PERF</DefineConstants>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)' == 'Release'">
    <Optimize Condition="'$(Optimize)' == ''">true</Optimize>
    <DebugType Condition="'$(DebugType)' == ''">pdbonly</DebugType>
    <DefineConstants>$(DefineConstants);TRACE;XUNIT_PERF</DefineConstants>
  </PropertyGroup>
  <PropertyGroup Condition="'$(Configuration)' == 'Checked'">
    <Optimize Condition="'$(Optimize)' == ''">true</Optimize>
    <DebugType Condition="'$(DebugType)' == ''">full</DebugType>
    <DefineConstants>$(DefineConstants);DEBUG;TRACE;XUNIT_PERF</DefineConstants>
  </PropertyGroup>

  <!-- Setup the default output and intermediate paths -->
  <PropertyGroup>
    <SkipXunitDependencyCopying>true</SkipXunitDependencyCopying>
  </PropertyGroup>

  <!-- Disable some standard properties for building our projects -->
  <PropertyGroup>
    <NoExplicitReferenceToStdLib>true</NoExplicitReferenceToStdLib>
    <AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences>
    <GenerateTargetFrameworkAttribute>false</GenerateTargetFrameworkAttribute>
    <!-- Disable some C# warnings for the tests. -->
    <NoWarn>78,162,164,168,169,219,251,252,414,429,618,642,649,652,659,675,1691,1717,1718,3001,3002,3003,3005,3008,SYSLIB0004,SYSLIB0011,SYSLIB0012</NoWarn>
    <RunAnalyzers>false</RunAnalyzers>
    <GenerateAssemblyInfo>false</GenerateAssemblyInfo>
    <SkipSigning Condition="'$(CrossGen)' == 'true'">true</SkipSigning>
    <AssemblyKey>Test</AssemblyKey>
    <GenerateDependencyFile>false</GenerateDependencyFile>
    <GenerateRuntimeConfigurationFiles>false</GenerateRuntimeConfigurationFiles>
    <CopyLocalLockFileAssemblies>false</CopyLocalLockFileAssemblies>
    <UseAppHost>false</UseAppHost>
  </PropertyGroup>

  <!-- Set arch specific properties -->
  <PropertyGroup>
    <TargetBits>32</TargetBits>
    <TargetBits Condition="'$(TargetArchitecture)'=='x64'">64</TargetBits>
    <TargetBits Condition="'$(TargetArchitecture)'=='arm64'">64</TargetBits>
  </PropertyGroup>

  <PropertyGroup>
    <TargetsUnknownUnix Condition="'$(TargetsUnix)' == 'true' AND '$(TargetOS)' != 'FreeBSD' AND '$(TargetOS)' != 'Linux' AND '$(TargetOS)' != 'NetBSD' AND '$(TargetOS)' != 'OSX' AND '$(TargetOS)' != 'illumos' AND '$(TargetOS)' != 'Solaris'">true</TargetsUnknownUnix>
    <Language Condition="'$(Language)' == '' and  '$(MSBuildProjectExtension)' == '.csproj'">C#</Language>
    <Language Condition="'$(Language)' == '' and  '$(MSBuildProjectExtension)' == '.fsproj'">F#</Language>
    <Language Condition="'$(Language)' == '' and  '$(MSBuildProjectExtension)' == '.ilproj'">IL</Language>
  </PropertyGroup>

  <!-- Don't reference the mscorlib facade -->
  <PropertyGroup>
    <ExcludeMscorlibFacade>true</ExcludeMscorlibFacade>
  </PropertyGroup>

  <!-- Set default ZapRequire level (used only when CrossGen is enabled) -->
  <PropertyGroup>
    <ZapRequire Condition="'$(ZapRequire)' == ''">2</ZapRequire>
  </PropertyGroup>

  <PropertyGroup>
    <!-- Specify the target framework of the common test dependency project.json. -->
    <NuGetTargetMoniker>$(NetCoreAppCurrentToolTargetFrameworkMoniker)</NuGetTargetMoniker>
    <NuGetTargetMonikerShort>$(NetCoreAppToolCurrent)</NuGetTargetMonikerShort>
  </PropertyGroup>

  <!-- Set Test Wrapper running host OS -->
  <PropertyGroup>
    <TestWrapperTargetsWindows>false</TestWrapperTargetsWindows>
    <TestWrapperTargetsWindows Condition=" ('$(TargetsWindows)' != '' And '$(TargetsWindows)' ) OR ('$(TargetOS)' == 'Android' And '$(TargetArchitecture)' == 'arm64' )">true</TestWrapperTargetsWindows>
  </PropertyGroup>

  <PropertyGroup>
    <!-- Scenario tests install this version of Microsoft.NetCore.App, then patch coreclr binaries via xcopy. At the moment it is
         updated manually whenever breaking changes require it to move forward, but it would be nice if we could update it automatically
         as we do with many of the package versions above -->
    <BaselineMicrosoftNetCoreAppPackageVersion>2.1.0-preview3-26416-01</BaselineMicrosoftNetCoreAppPackageVersion>
  </PropertyGroup>
</Project>