forked from dotnet/corefx
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make CoreFx.Private.TestUtilites RID-agnostic (dotnet#36207)
* Make CoreFx.Private.TestUtilites RID-agnostic * Add version checks for other distros dotnet@4f0d107 Porting fix over into PlatformDetection. * Build test lib in advance for VS support * Disable pretest in AllConfigurations
- Loading branch information
1 parent
0decf07
commit d3d144f
Showing
67 changed files
with
641 additions
and
1,940 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
src/Common/tests/CoreFx.Private.TestUtilities/CoreFx.Private.TestUtilities.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
<PropertyGroup> | ||
<ProjectGuid>{EBDB0247-CA43-4226-B7A1-8FEF21061D09}</ProjectGuid> | ||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks> | ||
<NoWarn>$(NoWarn);CS1573</NoWarn> | ||
<!-- | ||
This assembly is referenced from rid agnostic configurations therefore we can't make it RID specific | ||
and instead use runtime checks. | ||
--> | ||
<Configurations>netcoreapp-Debug;netcoreapp-Release;netstandard-Debug;netstandard-Release</Configurations> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<Compile Include="System\AdminHelpers.cs" /> | ||
<Compile Include="System\AssertExtensions.cs" /> | ||
<Compile Include="System\RetryHelper.cs" /> | ||
<Compile Include="System\Buffers\BoundedMemory.cs" /> | ||
<Compile Include="System\Buffers\BoundedMemory.Creation.cs" /> | ||
<Compile Include="System\Buffers\BoundedMemory.Unix.cs" /> | ||
<Compile Include="System\Buffers\BoundedMemory.Windows.cs" /> | ||
<Compile Include="System\Buffers\PoisonPagePlacement.cs" /> | ||
<Compile Include="System\IO\FileCleanupTestBase.cs" /> | ||
<Compile Include="System\TestEnvironment.cs" /> | ||
<!-- We don't compile per but and instead use runtime platform checks. --> | ||
<Compile Include="System\PlatformDetection.cs" /> | ||
<Compile Include="System\PlatformDetection.Unix.cs" /> | ||
<Compile Include="System\PlatformDetection.Windows.cs" /> | ||
<!-- | ||
Interop.Library is not designed to support runtime checks therefore we are picking the Windows | ||
variant from the Common folder and adding the missing members manually. | ||
--> | ||
<Compile Include="Interop\Interop.Libraries.cs" /> | ||
</ItemGroup> | ||
<!-- Windows imports --> | ||
<ItemGroup> | ||
<Compile Include="$(CommonPath)\CoreLib\Interop\Windows\Kernel32\Interop.GetCurrentProcess_IntPtr.cs"> | ||
<Link>Common\Interop\Windows\Kernel32\Interop.GetCurrentProcess_IntPtr.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\NtDll\Interop.RTL_OSVERSIONINFOEX.cs"> | ||
<Link>Common\Interop\Windows\NtDll\Interop.RTL_OSVERSIONINFOEX.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\NtDll\Interop.RtlGetVersion.cs"> | ||
<Link>Common\Interop\Windows\NtDll\Interop.RtlGetVersion.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\Advapi32\Interop.OpenProcessToken_SafeAccessTokenHandle.cs"> | ||
<Link>Common\Interop\Windows\Advapi32\Interop.OpenProcessToken_SafeAccessTokenHandle.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\Interop.Libraries.cs"> | ||
<Link>Common\Interop\Windows\Interop.Libraries.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\CoreLib\Interop\Windows\Kernel32\Interop.CloseHandle.cs"> | ||
<Link>Common\CoreLib\Interop\Windows\Kernel32\Interop.CloseHandle.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\Advapi32\Interop.TOKEN_INFORMATION_CLASS.cs"> | ||
<Link>Common\Interop\Windows\Advapi32\Interop.TOKEN_INFORMATION_CLASS.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\Advapi32\Interop.GetTokenInformation_void.cs"> | ||
<Link>Common\Interop\Windows\Advapi32\Interop.GetTokenInformation_void.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\Interop\Windows\Advapi32\Interop.TOKEN_ELEVATION.cs"> | ||
<Link>Common\Interop\Windows\Advapi32\Interop.TOKEN_ELEVATION.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\CoreLib\Interop\Windows\Interop.BOOL.cs"> | ||
<Link>Common\CoreLib\Interop\Windows\Interop.BOOL.cs</Link> | ||
</Compile> | ||
</ItemGroup> | ||
<!-- Unix imports --> | ||
<ItemGroup> | ||
<Compile Include="$(CommonPath)\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSslVersion.cs"> | ||
<Link>Common\Interop\Unix\System.Security.Cryptography.Native\Interop.OpenSslVersion.cs</Link> | ||
</Compile> | ||
<Compile Include="$(CommonPath)\CoreLib\Interop\Unix\System.Native\Interop.GetEUid.cs"> | ||
<Link>Common\Interop\Unix\Interop.GetEUid.cs</Link> | ||
</Compile> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Microsoft.DotNet.XUnitExtensions" Version="$(MicrosoftDotNetXUnitExtensionsPackageVersion)" /> | ||
<PackageReference Include="xunit.core" Version="$(XUnitPackageVersion)" ExcludeAssets="build" /> | ||
<PackageReference Include="xunit.assert" Version="$(XUnitPackageVersion)" /> | ||
<PackageReference Include="Microsoft.DotNet.PlatformAbstractions" Version="$(MicrosoftDotNetPlatformAbstractionsPackageVersion)" /> | ||
</ItemGroup> | ||
</Project> |
13 changes: 13 additions & 0 deletions
13
src/Common/tests/CoreFx.Private.TestUtilities/Interop/Interop.Libraries.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information. | ||
|
||
internal static partial class Interop | ||
{ | ||
internal static partial class Libraries | ||
{ | ||
// Shims | ||
public const string CryptoNative = "System.Security.Cryptography.Native.OpenSsl"; | ||
public const string SystemNative = "System.Native"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.