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

github.com/mono/corefx.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorEric StJohn <ericstj@microsoft.com>2018-03-30 18:04:00 +0300
committerGitHub <noreply@github.com>2018-03-30 18:04:00 +0300
commitef52017da09efe47200479001988e924720598b0 (patch)
tree14043bcc0bc7c451568a5b8bc2b27908773fde3a /pkg
parent458ee023de704eb468f0a7cbaa5924828e57aeb0 (diff)
parent2d420dddeaa0c21b37550dc69a76c6da66b6d1f7 (diff)
Merge pull request #28600 from ericstj/packageTesting
Fix package testing infrastructure and fix issues.
Diffstat (limited to 'pkg')
-rw-r--r--pkg/test/frameworkSettings/netcoreapp/settings.targets5
-rw-r--r--pkg/test/frameworkSettings/netcoreapp2.0/settings.targets9
-rw-r--r--pkg/test/frameworkSettings/netcoreapp2.1/settings.targets9
-rw-r--r--pkg/test/frameworkSettings/netstandard/settings.targets8
-rw-r--r--pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.0/settings.targets7
-rw-r--r--pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.1/settings.targets7
-rw-r--r--pkg/test/packageSettings/System.Buffers/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Diagnostics.DiagnosticSource/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Reflection.TypeExtensions/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Runtime.CompilerServices.Unsafe/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Security.Cryptography.Cng/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Security.Cryptography.OpenSsl/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Security.Principal.Windows/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageSettings/System.Threading.Tasks.Extensions/netcoreapp1.0/workaroundDowngrade.targets7
-rw-r--r--pkg/test/packageTest.targets3
-rw-r--r--pkg/test/testPackages.proj25
16 files changed, 122 insertions, 7 deletions
diff --git a/pkg/test/frameworkSettings/netcoreapp/settings.targets b/pkg/test/frameworkSettings/netcoreapp/settings.targets
index d4cd7ba326..628d07c1db 100644
--- a/pkg/test/frameworkSettings/netcoreapp/settings.targets
+++ b/pkg/test/frameworkSettings/netcoreapp/settings.targets
@@ -7,6 +7,7 @@
<ShouldVerifyTypes>true</ShouldVerifyTypes>
<!-- ensure that we get runtime assemblies in ReferenceCopyLocalPaths -->
+ <SelfContained>true</SelfContained>
<CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies>
</PropertyGroup>
@@ -14,5 +15,9 @@
<!-- intentionally dangling refs in shims -->
<ExcludeFromClosure Include="@(NetFxReference)" />
<IgnoredReference Include="@(NetFxReference)" />
+
+ <!-- netstandard will have cycles because OOB packages target netstandard and are used in netstandard closure,
+ We do ensure that netstandard inside the shared framework has no cycles, but we permit them in packages in order to allow for simpler netstandard-based builds.-->
+ <IgnoredReference Include="netstandard" />
</ItemGroup>
</Project> \ No newline at end of file
diff --git a/pkg/test/frameworkSettings/netcoreapp2.0/settings.targets b/pkg/test/frameworkSettings/netcoreapp2.0/settings.targets
new file mode 100644
index 0000000000..e36a61bdac
--- /dev/null
+++ b/pkg/test/frameworkSettings/netcoreapp2.0/settings.targets
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup Condition="'$(RuntimeIdentifier)' != ''">
+ <!-- NETCoreApp2.0 had experimental versions of Span and ReadOnlySpan
+ which we don't match the final API nor were they ship-quality -->
+ <IgnoredTypes Include="System.ReadOnlySpan`1" />
+ <IgnoredTypes Include="System.Span`1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/frameworkSettings/netcoreapp2.1/settings.targets b/pkg/test/frameworkSettings/netcoreapp2.1/settings.targets
new file mode 100644
index 0000000000..949dc4c30a
--- /dev/null
+++ b/pkg/test/frameworkSettings/netcoreapp2.1/settings.targets
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <!-- Enable targeting netcoreapp2.1 even in an older CLI -->
+ <NETCoreAppMaximumVersion>2.1</NETCoreAppMaximumVersion>
+ <!-- use the most recent MS.NETCore.App we have from upstack -->
+ <RuntimeFrameworkVersion>$(MicrosoftNETCoreAppPackageVersion)</RuntimeFrameworkVersion>
+ </PropertyGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/frameworkSettings/netstandard/settings.targets b/pkg/test/frameworkSettings/netstandard/settings.targets
index 67ee4260cc..819cd00b66 100644
--- a/pkg/test/frameworkSettings/netstandard/settings.targets
+++ b/pkg/test/frameworkSettings/netstandard/settings.targets
@@ -1,7 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$(ToolsDir)netfxreference.props" />
+
<PropertyGroup>
<ShouldVerifyClosure>true</ShouldVerifyClosure>
<ShouldVerifyTypes>true</ShouldVerifyTypes>
</PropertyGroup>
+
+ <ItemGroup>
+ <!-- intentionally dangling refs in shims -->
+ <ExcludeFromClosure Include="@(NetFxReference)" />
+ <IgnoredReference Include="@(NetFxReference)" />
+ </ItemGroup>
</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.0/settings.targets b/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.0/settings.targets
new file mode 100644
index 0000000000..3056cd46cd
--- /dev/null
+++ b/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.0/settings.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <!-- This package intentionally drops all runtime-package mappings from runtime.json -->
+ <ShouldVerifyClosure>false</ShouldVerifyClosure>
+ </PropertyGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.1/settings.targets b/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.1/settings.targets
new file mode 100644
index 0000000000..3056cd46cd
--- /dev/null
+++ b/pkg/test/packageSettings/Microsoft.NETCore.Targets/netcoreapp1.1/settings.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <!-- This package intentionally drops all runtime-package mappings from runtime.json -->
+ <ShouldVerifyClosure>false</ShouldVerifyClosure>
+ </PropertyGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Buffers/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Buffers/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Buffers/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Diagnostics.DiagnosticSource/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Diagnostics.DiagnosticSource/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Diagnostics.DiagnosticSource/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Reflection.TypeExtensions/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Reflection.TypeExtensions/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Reflection.TypeExtensions/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Runtime.CompilerServices.Unsafe/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Runtime.CompilerServices.Unsafe/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Runtime.CompilerServices.Unsafe/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Security.Cryptography.Cng/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Security.Cryptography.Cng/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Security.Cryptography.Cng/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Security.Cryptography.OpenSsl/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Security.Cryptography.OpenSsl/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Security.Cryptography.OpenSsl/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Security.Principal.Windows/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Security.Principal.Windows/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Security.Principal.Windows/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageSettings/System.Threading.Tasks.Extensions/netcoreapp1.0/workaroundDowngrade.targets b/pkg/test/packageSettings/System.Threading.Tasks.Extensions/netcoreapp1.0/workaroundDowngrade.targets
new file mode 100644
index 0000000000..1ec61540e4
--- /dev/null
+++ b/pkg/test/packageSettings/System.Threading.Tasks.Extensions/netcoreapp1.0/workaroundDowngrade.targets
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <!-- issue https://github.com/dotnet/corefx/issues/28551 -->
+ <PackageReference Include="NETStandard.Library" Version="1.6.1" />
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/pkg/test/packageTest.targets b/pkg/test/packageTest.targets
index 559d5bfe36..9287f897f0 100644
--- a/pkg/test/packageTest.targets
+++ b/pkg/test/packageTest.targets
@@ -8,6 +8,7 @@
</PropertyGroup>
<Import Project="tools\Packaging.common.targets" />
+ <Import Project="tools\dependencies.props" />
<Import Project="frameworkSettings\$(_targetFrameworkIdentifier)\*.targets" />
<Import Project="frameworkSettings\$(TargetFramework)\*.targets" />
<Import Project="packageSettings\$(TestPackageId)\*.targets" />
@@ -56,7 +57,7 @@
<Target Name="VerifyRuntimeClosure"
DependsOnTargets="ResolveReferences"
- Condition="'$(ShouldVerifyClosure)' == 'true' AND '$(RuntimeIdentifier)' != '' AND '@(ReferenceCopyLocalPaths)' != ''">
+ Condition="'$(ShouldVerifyClosure)' == 'true' AND '$(RuntimeIdentifier)' != ''">
<ItemGroup>
<_runClosureFileNames Include="@(ReferenceCopyLocalPaths->'%(FileName)')">
<Original>%(Identity)</Original>
diff --git a/pkg/test/testPackages.proj b/pkg/test/testPackages.proj
index ac96cb3980..1bec7d40b5 100644
--- a/pkg/test/testPackages.proj
+++ b/pkg/test/testPackages.proj
@@ -4,20 +4,24 @@
<ItemGroup>
<TestPackages Condition="'$(TestPackages)' != ''" Include="$(TestPackages)" />
- <PackageReports Condition="'@(TestPackages)' == ''" Include="$(PackageReportDir)*.json" />
+ <ExcludePackages Include="CoreFx.Private.TestUtilities" />
+ <ExcludePackages Include="$(ExcludePackages)" />
+
+ <PackageReports Condition="'@(TestPackages)' == ''" Include="$(PackageReportDir)*.json" Exclude="@(ExcludePackages->'$(PackageReportDir)%(Identity).json')"/>
<PackageReports Condition="'@(TestPackages)' != ''" Include="@(TestPackages->'$(PackageReportDir)%(Identity).json')" />
<!-- support override via commandline -->
<RuntimesToInclude Condition="'$(RuntimesToInclude)' != ''" Include="$(RuntimesToInclude)" />
<TargetFrameworksToInclude Condition="'$(TargetFrameworksToInclude)' != ''" Include="$(TargetFrameworksToInclude)" />
-
- <!-- restrict restore sources to the current build and publicly shipped packages -->
- <RestoreSource Include="$(PackageOutputPath)" />
+
<RestoreSource Include="https:%2F%2Fapi.nuget.org/v3/index.json" />
<!-- needed for SQLClient's SNI packages -->
<RestoreSource Include="https:%2F%2Fdotnet.myget.org/F/dotnet-core/api/v3/index.json" />
+ <!-- ideally this would be first, but we need to list last to workaround https://github.com/NuGet/Home/issues/6678 -->
+ <RestoreSource Include="$(PackageOutputPath)" />
+
<!-- we don't build alpine or older OSX versions -->
<RuntimesToExclude Include="alpine.3.4.3-x64;osx.10.10-x64;osx.10.11-x64" />
@@ -56,6 +60,9 @@
<TestSupportFiles Include="$(SourceDir)shims\netfxreference.props">
<DestinationFolder>$(TestToolsDir)</DestinationFolder>
</TestSupportFiles>
+ <TestSupportFiles Include="$(ProjectDir)dependencies.props">
+ <DestinationFolder>$(TestToolsDir)</DestinationFolder>
+ </TestSupportFiles>
<TestSupportFiles Include="$(ToolsDir)Packaging.common.targets">
<DestinationFolder>$(TestToolsDir)</DestinationFolder>
</TestSupportFiles>
@@ -75,6 +82,12 @@
<DestinationFolder>$(TestDir)</DestinationFolder>
</TestSupportFiles>
</ItemGroup>
+
+ <ItemGroup>
+ <CliEnvironment Include="DOTNET_CLI_TELEMETRY_OPTOUT=1" />
+ <CliEnvironment Include="DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1" />
+ <CliEnvironment Include="DOTNET_MULTILEVEL_LOOKUP=0" />
+ </ItemGroup>
<Target Name="CreateTestDir"
Inputs="@(TestSupportFiles)"
@@ -155,13 +168,13 @@
<Target Name="RestoreProjects"
DependsOnTargets="GenerateProjects">
<Message Importance="High" Text="*** Restoring ***" />
- <Exec Command="$(TestRestoreCommand) &quot;$(TestProject)&quot;" StandardOutputImportance="High" />
+ <Exec Command="$(TestRestoreCommand) &quot;$(TestProject)&quot;" EnvironmentVariables="@(CliEnvironment)" ContinueOnError="ErrorAndContinue" StandardOutputImportance="High" />
</Target>
<Target Name="BuildProjects"
DependsOnTargets="RestoreProjects">
<Message Importance="High" Text="*** Testing ***" />
- <Exec Command="$(TestBuildCommand) &quot;$(TestProject)&quot; /p:TestPackages=%(SupportedPackage.Identity)" StandardOutputImportance="High" />
+ <Exec Command="$(TestBuildCommand) &quot;$(TestProject)&quot; /p:TestPackages=%(SupportedPackage.Identity)" EnvironmentVariables="@(CliEnvironment)" ContinueOnError="ErrorAndContinue" StandardOutputImportance="High" />
</Target>
<Target Name="Build" DependsOnTargets="BuildProjects" />