Refactor tests to use CliTargetFramework variable instead of hard-coding target framework
This commit is contained in:
parent
c6925a5388
commit
ec9914424c
11 changed files with 17 additions and 12 deletions
|
@ -28,12 +28,9 @@ tools\TestAssetsDependencies\TestAssetsDependencies.csproj
|
|||
|
||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
||||
<DisableImplicitPackageTargetFallback>true</DisableImplicitPackageTargetFallback>
|
||||
|
||||
<CliTargetFramework>netcoreapp3.0</CliTargetFramework>
|
||||
<!-- We only need this until we get a stage0 with a 3.0 SDK. -->
|
||||
<NETCoreAppMaximumVersion>3.0</NETCoreAppMaximumVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="build/TargetFramework.props" />
|
||||
<Import Project="build/InitRepo.props" />
|
||||
<Import Condition=" '$(GeneratePropsFile)' != 'true' " Project="$(GitCommitInfoProps)" />
|
||||
<Import Condition=" '$(GeneratePropsFile)' != 'true' " Project="$(HostInfoProps)" />
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<VersionPrefix>1.0.0-rc</VersionPrefix>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<OutputType>Exe</OutputType>
|
||||
<VersionSuffix></VersionSuffix>
|
||||
</PropertyGroup>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<OutputType>Exe</OutputType>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<OutputType>Exe</OutputType>
|
||||
<VersionSuffix></VersionSuffix>
|
||||
</PropertyGroup>
|
||||
|
|
|
@ -3,6 +3,6 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<RuntimeIdentifiers>win7-x64;win7-x86;osx.10.12-x64;ubuntu.14.04-x64;ubuntu.16.04-x64;ubuntu.16.10-x64;rhel.6-x64;centos.7-x64;rhel.7-x64;debian.8-x64;fedora.24-x64;opensuse.42.1-x64;linux-musl-x64</RuntimeIdentifiers>
|
||||
<RestoreAdditionalProjectSources Condition="'$(TEST_PACKAGES)' != ''">$(TEST_PACKAGES)</RestoreAdditionalProjectSources>
|
||||
</PropertyGroup>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<RestoreAdditionalProjectSources Condition="'$(TEST_PACKAGES)' != ''">$(TEST_PACKAGES)</RestoreAdditionalProjectSources>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
7
build/TargetFramework.props
Normal file
7
build/TargetFramework.props
Normal file
|
@ -0,0 +1,7 @@
|
|||
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<CliTargetFramework>netcoreapp3.0</CliTargetFramework>
|
||||
<!-- We only need this until we get a stage0 with a 3.0 SDK. -->
|
||||
<NETCoreAppMaximumVersion>3.0</NETCoreAppMaximumVersion>
|
||||
</PropertyGroup>
|
||||
</Project>
|
|
@ -2,6 +2,7 @@
|
|||
<PropertyGroup>
|
||||
<RepoRoot>$(MSBuildThisFileDirectory)</RepoRoot>
|
||||
</PropertyGroup>
|
||||
<Import Project="build/TargetFramework.props" />
|
||||
<Import Project="build/InitRepo.props" />
|
||||
<Import Project="build/DependencyVersions.props" />
|
||||
<PropertyGroup>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>netcoreapp2.2</TargetFramework>
|
||||
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||
<RuntimeIdentifier>$(SharedFrameworkRid)</RuntimeIdentifier>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
Loading…
Reference in a new issue