Merge branch 'release/2.1' into release/2.2

This commit is contained in:
Nate McMaster 2018-07-05 10:21:51 -07:00
commit 71de7a98f5
No known key found for this signature in database
GPG Key ID: A778D9601BD78810
5 changed files with 23 additions and 35 deletions

View File

@ -530,15 +530,16 @@
<Target Name="BuildSharedFx" DependsOnTargets="GeneratePropsFiles;ResolveSharedFxFiles;CrossGenAssemblies;CrossGenSymbols;PackSharedFx;TestSharedFx"/>
<PropertyGroup>
<UnitTestFxProject>$(RepositoryRoot)\test\SharedFx.UnitTests\SharedFx.UnitTests.csproj</UnitTestFxProject>
<UnitTestFxTrxLogFile>$(LogOutputDir)SharedFx-UnitTests.trx</UnitTestFxTrxLogFile>
<UnitTestFxTrxPhysicalFilePath>$(UnitTestFxTrxLogFile)</UnitTestFxTrxPhysicalFilePath>
<UnitTestFxTrxPhysicalFilePath Condition="'$(HostMachineRepositoryRoot)' != ''">$(HostMachineRepositoryRoot)/artifacts/logs/SharedFx-UnitTests.trx</UnitTestFxTrxPhysicalFilePath>
</PropertyGroup>
<Target Name="TestSharedFx" DependsOnTargets="DefineSharedFxPrerequisites;ResolveCommitHash;InstallDotNet">
<Target Name="TestSharedFx" DependsOnTargets="GeneratePropsFiles;DefineSharedFxPrerequisites;ResolveCommitHash;InstallDotNet">
<PropertyGroup>
<UnitTestFxProject>$(RepositoryRoot)\test\SharedFx.UnitTests\SharedFx.UnitTests.csproj</UnitTestFxProject>
<!-- The file path to the log file, from within the container -->
<UnitTestFxTrxLogFile>$(LogOutputDir)SharedFx-UnitTests-$(Version).trx</UnitTestFxTrxLogFile>
<!-- The trx file path from the perspective of the TeamCity agent -->
<UnitTestFxTrxPhysicalFilePath>$(UnitTestFxTrxLogFile)</UnitTestFxTrxPhysicalFilePath>
<UnitTestFxTrxPhysicalFilePath Condition="'$(HostMachineRepositoryRoot)' != ''">$(HostMachineRepositoryRoot)/artifacts/logs/SharedFx-UnitTests.trx</UnitTestFxTrxPhysicalFilePath>
<UnitTestFxTestProps>
DotNetRestoreSourcePropsPath=$(GeneratedRestoreSourcesPropsPath);
DotNetPackageVersionPropsPath=$(GeneratedPackageVersionPropsPath);
@ -549,15 +550,21 @@
</UnitTestFxTestProps>
</PropertyGroup>
<MSBuild Projects="$(UnitTestFxProject)" Targets="Restore" Properties="_Dummy=restore;$(UnitTestFxTestProps)" />
<MSBuild Projects="$(UnitTestFxProject)" Targets="VSTest" Properties="$(UnitTestFxTestProps)" />
<CallTarget Targets="ReportTestSharedFxTrx" />
<OnError ExecuteTargets="ReportTestSharedFxTrx" />
</Target>
<MSBuild Projects="$(UnitTestFxProject)" Targets="Build" Properties="$(UnitTestFxTestProps)">
<Output TaskParameter="TargetOutputs" ItemName="SharedFxTestAssembly" />
</MSBuild>
<RunDotNet Arguments="vstest;
--Framework:%(TargetFrameworkIdentifier),Version=v%(TargetFrameworkVersion);
--Logger:$([MSBuild]::Escape('trx;LogFileName=$(UnitTestFxTrxLogFile)'));
%(SharedFxTestAssembly.Identity);
--;RunConfiguration.NoAutoReporters=true" IgnoreExitCode="true">
<Output TaskParameter="ExitCode" PropertyName="VsTestExitCode" />
</RunDotNet>
<Target Name="ReportTestSharedFxTrx">
<Message Text="##teamcity[importData type='vstest' path='$(UnitTestFxTrxPhysicalFilePath)']"
Importance="high"
Condition=" '$(TEAMCITY_VERSION)' != '' AND Exists('$(UnitTestFxTrxLogFile)') "/>
Importance="High"
Condition="'$(TEAMCITY_VERSION)' != '' AND Exists('$(UnitTestFxTrxLogFile)')" />
<Error Text="SharedFx.UnitTests failed with exit code '$(VsTestExitCode)'." Condition=" $(VsTestExitCode) != 0 " />
</Target>
</Project>

View File

@ -38,7 +38,6 @@
<PropertyGroup>
<!-- Assign this variable last because it may be updated from DotNetPackageVersionPropsPath as MicrosoftNETCoreAppPackageVersion. -->
<MicrosoftNETCoreApp22PackageVersion Condition="'$(MicrosoftNETCoreAppPackageVersion)' != ''">$(MicrosoftNETCoreAppPackageVersion)</MicrosoftNETCoreApp22PackageVersion>
<MicrosoftNETCoreAppPackageVersion Condition="'$(MicrosoftNETCoreAppPackageVersion)' == ''">$(MicrosoftNETCoreApp22PackageVersion)</MicrosoftNETCoreAppPackageVersion>
<!-- Determined by build tools -->
<InternalAspNetCoreSdkPackageVersion>$(KoreBuildVersion)</InternalAspNetCoreSdkPackageVersion>

View File

@ -25,14 +25,3 @@ ENV LANG en_US.UTF-8
# Skip package initilization
ENV DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
# Workarounds https://github.com/dotnet/cli/issues/8738
ENV DOTNET_INSTALL_SKIP_PREREQS=1
ENV KOREBUILD_SKIP_RUNTIME_INSTALL=1
COPY global.json /tmp/global.json
RUN DOTNET_SDK_VERSION="$(jq -r '.sdk.version' /tmp/global.json)" \
&& echo "Installing SDK ${DOTNET_SDK_VERSION}" \
&& wget -q --tries 10 -O /tmp/dotnet.tar.gz https://dotnetcli.blob.core.windows.net/dotnet/Sdk/$DOTNET_SDK_VERSION/dotnet-sdk-$DOTNET_SDK_VERSION-linux-musl-x64.tar.gz \
&& mkdir -p "$HOME/.dotnet" \
&& tar xzf /tmp/dotnet.tar.gz -C "$HOME/.dotnet"

View File

@ -90,13 +90,6 @@ fi
dockerfile="$DIR/build/docker/$image.Dockerfile"
tagname="universe-build-$image"
# Workaround for https://github.com/dotnet/cli/issues/8738 and https://github.com/Microsoft/msbuild/issues/3066
# Run noop target because we need to generate the global.json file so we can install the matching
# .NET Core SDK inside the Docker container.
"$DIR/build.sh" /t:Noop
cp "$DIR/global.json" "$(dirname "$dockerfile")"
#endworkaround
docker build "$(dirname "$dockerfile")" \
--build-arg "USER=$(whoami)" \
--build-arg "USER_ID=$(id -u)" \

View File

@ -24,7 +24,7 @@
</AssemblyAttribute>
<AssemblyAttribute Include="Microsoft.AspNetCore.TestData">
<_Parameter1>MicrosoftNETCoreAppPackageVersion</_Parameter1>
<_Parameter2>$(MicrosoftNETCoreAppPackageVersion)</_Parameter2>
<_Parameter2>$(RuntimeFrameworkVersion)</_Parameter2>
</AssemblyAttribute>
</ItemGroup>