You've already forked linux-packaging-mono
Imported Upstream version 5.4.0.167
Former-commit-id: 5624ac747d633e885131e8349322922b6a59baaa
This commit is contained in:
parent
e49d6f06c0
commit
536cd135cc
4
external/corefx/src/System.Buffers/dir.props
vendored
4
external/corefx/src/System.Buffers/dir.props
vendored
@@ -2,9 +2,9 @@
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="..\dir.props" />
|
||||
<PropertyGroup>
|
||||
<AssemblyVersion>4.0.2.0</AssemblyVersion>
|
||||
<AssemblyVersion>4.0.3.0</AssemblyVersion>
|
||||
<AssemblyKey>Open</AssemblyKey>
|
||||
<IsNETCoreApp>true</IsNETCoreApp>
|
||||
<IsUAP>true</IsUAP>
|
||||
<IsUAPRef>false</IsUAPRef>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -7,6 +7,8 @@
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\src\System.Buffers.csproj" />
|
||||
|
||||
<InboxOnTargetFramework Include="netcoreapp2.0" />
|
||||
<InboxOnTargetFramework Include="uap10.1" />
|
||||
<!-- this package is part of the implementation closure of NETStandard.Library
|
||||
therefore it cannot reference NETStandard.Library -->
|
||||
<SuppressMetaPackage Include="NETStandard.Library" />
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" />
|
||||
<PropertyGroup>
|
||||
<ProjectGuid>{11AE73F7-3532-47B9-8FF6-B4F22D76456C}</ProjectGuid>
|
||||
<UseOpenKey>true</UseOpenKey>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'netstandard-Debug|AnyCPU'" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'netstandard-Release|AnyCPU'" />
|
||||
|
||||
@@ -1,9 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<BuildConfigurations>
|
||||
<PackageConfigurations>
|
||||
netstandard1.1;
|
||||
netstandard;
|
||||
</PackageConfigurations>
|
||||
<BuildConfigurations>
|
||||
$(PackageConfigurations);
|
||||
netcoreapp-Windows_NT;
|
||||
netcoreapp-Unix;
|
||||
uap-Windows_NT;
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
<ProjectGuid>{2ADDB484-6F57-4D71-A3FE-A57EC6329A2B}</ProjectGuid>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
<DocumentationFile>$(OutputPath)$(MSBuildProjectName).xml</DocumentationFile>
|
||||
<UseOpenKey>true</UseOpenKey>
|
||||
<IsPartialFacadeAssembly Condition="'$(TargetGroup)' != 'netstandard' and '$(TargetGroup)' != 'netstandard1.1'">true</IsPartialFacadeAssembly>
|
||||
<ExcludeResourcesImport Condition="'$(IsPartialFacadeAssembly)'=='true'">true</ExcludeResourcesImport>
|
||||
</PropertyGroup>
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
// The .NET Foundation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.Tracing;
|
||||
using System.Linq;
|
||||
@@ -47,7 +48,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
[InlineData(-1)]
|
||||
public static void CreatingAPoolWithInvalidArrayCountThrows(int length)
|
||||
{
|
||||
Assert.Throws<ArgumentOutOfRangeException>("maxArraysPerBucket", () => ArrayPool<byte>.Create(maxArraysPerBucket: length, maxArrayLength: 16));
|
||||
AssertExtensions.Throws<ArgumentOutOfRangeException>("maxArraysPerBucket", () => ArrayPool<byte>.Create(maxArraysPerBucket: length, maxArrayLength: 16));
|
||||
}
|
||||
|
||||
[Theory]
|
||||
@@ -55,7 +56,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
[InlineData(-1)]
|
||||
public static void CreatingAPoolWithInvalidMaximumArraySizeThrows(int length)
|
||||
{
|
||||
Assert.Throws<ArgumentOutOfRangeException>("maxArrayLength", () => ArrayPool<byte>.Create(maxArrayLength: length, maxArraysPerBucket: 1));
|
||||
AssertExtensions.Throws<ArgumentOutOfRangeException>("maxArrayLength", () => ArrayPool<byte>.Create(maxArrayLength: length, maxArraysPerBucket: 1));
|
||||
}
|
||||
|
||||
[Theory]
|
||||
@@ -74,7 +75,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
[MemberData(nameof(BytePoolInstances))]
|
||||
public static void RentingWithInvalidLengthThrows(ArrayPool<byte> pool)
|
||||
{
|
||||
Assert.Throws<ArgumentOutOfRangeException>("minimumLength", () => pool.Rent(-1));
|
||||
AssertExtensions.Throws<ArgumentOutOfRangeException>("minimumLength", () => pool.Rent(-1));
|
||||
}
|
||||
|
||||
[Fact]
|
||||
@@ -145,7 +146,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
[MemberData(nameof(BytePoolInstances))]
|
||||
public static void CallingReturnBufferWithNullBufferThrows(ArrayPool<byte> pool)
|
||||
{
|
||||
Assert.Throws<ArgumentNullException>("array", () => pool.Return(null));
|
||||
AssertExtensions.Throws<ArgumentNullException>("array", () => pool.Return(null));
|
||||
}
|
||||
|
||||
private static void FillArray(byte[] buffer)
|
||||
@@ -413,6 +414,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ActiveIssue("https://github.com/dotnet/corefx/issues/20511", TargetFrameworkMonikers.UapAot)]
|
||||
public static void RentBufferFiresRentedDiagnosticEvent()
|
||||
{
|
||||
ArrayPool<byte> pool = ArrayPool<byte>.Create(maxArrayLength: 16, maxArraysPerBucket: 1);
|
||||
@@ -430,6 +432,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ActiveIssue("https://github.com/dotnet/corefx/issues/20511", TargetFrameworkMonikers.UapAot)]
|
||||
public static void ReturnBufferFiresDiagnosticEvent()
|
||||
{
|
||||
ArrayPool<byte> pool = ArrayPool<byte>.Create(maxArrayLength: 16, maxArraysPerBucket: 1);
|
||||
@@ -444,6 +447,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ActiveIssue("https://github.com/dotnet/corefx/issues/20511", TargetFrameworkMonikers.UapAot)]
|
||||
public static void RentingNonExistentBufferFiresAllocatedDiagnosticEvent()
|
||||
{
|
||||
ArrayPool<byte> pool = ArrayPool<byte>.Create(maxArrayLength: 16, maxArraysPerBucket: 1);
|
||||
@@ -451,6 +455,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ActiveIssue("https://github.com/dotnet/corefx/issues/20511", TargetFrameworkMonikers.UapAot)]
|
||||
public static void RentingBufferOverConfiguredMaximumSizeFiresDiagnosticEvent()
|
||||
{
|
||||
ArrayPool<byte> pool = ArrayPool<byte>.Create(maxArrayLength: 16, maxArraysPerBucket: 1);
|
||||
@@ -458,6 +463,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[ActiveIssue("https://github.com/dotnet/corefx/issues/20511", TargetFrameworkMonikers.UapAot)]
|
||||
public static void RentingManyBuffersFiresExpectedDiagnosticEvents()
|
||||
{
|
||||
ArrayPool<byte> pool = ArrayPool<byte>.Create(maxArrayLength: 16, maxArraysPerBucket: 10);
|
||||
@@ -480,7 +486,7 @@ namespace System.Buffers.ArrayPool.Tests
|
||||
[MemberData(nameof(BytePoolInstances))]
|
||||
public static void ReturningANonPooledBufferOfDifferentSizeToThePoolThrows(ArrayPool<byte> pool)
|
||||
{
|
||||
Assert.Throws<ArgumentException>("array", () => pool.Return(new byte[1]));
|
||||
AssertExtensions.Throws<ArgumentException>("array", () => pool.Return(new byte[1]));
|
||||
}
|
||||
|
||||
[Theory]
|
||||
|
||||
@@ -8,6 +8,9 @@
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'netstandard-Release|AnyCPU'" />
|
||||
<ItemGroup>
|
||||
<Compile Include="ArrayPool\UnitTests.cs" />
|
||||
<Compile Include="$(CommonTestPath)\System\AssertExtensions.cs">
|
||||
<Link>Common\System\AssertExtensions.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="$(CommonTestPath)\System\Diagnostics\Tracing\TestEventListener.cs" />
|
||||
</ItemGroup>
|
||||
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.targets))\dir.targets" />
|
||||
|
||||
Reference in New Issue
Block a user