[XHarness] Do use the test dlls from the mono downloads. (#6055)
This updates the project generation. We cannot yet fully remove the submodule because: * We are missing the xunit dlls which should be added in the SDK. * We have not yet remove all the old style tests. Would make the PR huge, better to deal with it in a diff PR. * The xunit CoreLib tests have issues loading all the tests, needs some extra work and again, the PR is already large. Fixes: xamarin/maccore#1199 Fixes: xamarin/maccore#1204 Fixes: xamarin/maccore#1209 Fixes: xamarin/maccore#1510
This commit is contained in:
Родитель
6ff6d313a2
Коммит
94fe39b118
|
@ -672,7 +672,7 @@ timestamps {
|
|||
uploadFiles ("tests/*.zip", "wrench", virtualPath)
|
||||
}
|
||||
|
||||
timeout (time: 10, unit: 'HOURS') {
|
||||
timeout (time: 13, unit: 'HOURS') {
|
||||
// We run tests locally and on older macOS bots in parallel.
|
||||
// The older macOS tests run quickly (and the bots should usually be idle),
|
||||
// which means that the much longer normal (local) test run should take
|
||||
|
|
|
@ -198,12 +198,6 @@ $(TOP)/tools/mtouch/SdkVersions.cs: $(TOP)/tools/common/SdkVersions.cs.in
|
|||
@$(MAKE) -C $(TOP)/src project-files
|
||||
@touch $@
|
||||
|
||||
.stamp-build-mono-unit-tests: $(TOP)/.git/modules/external/mono/HEAD
|
||||
make -j8 -C $(TOP)/external/mono/mcs/class -i do-test PROFILE=xammac_net_4_5 # TODO: This should not be needed and we should get the dlls from the SDK.
|
||||
make -j8 -C $(TOP)/external/mono/mcs/class -i do-xunit-test PROFILE=xammac_net_4_5 # TODO: This should not be needed and we should get the dlls from the SDK.
|
||||
nuget restore bcl-test/BCLTests/BCLTests.csproj
|
||||
$(Q) touch $@
|
||||
|
||||
xharness/xharness.exe: $(wildcard xharness/*.cs) $(wildcard $(TOP)/tools/bcl-test-importer/BCLTestImporter/*.cs) xharness/xharness.csproj $(TOP)/tools/mtouch/SdkVersions.cs test.config test-system.config .stamp-src-project-files
|
||||
nuget restore xharness/xharness.csproj
|
||||
$(Q_GEN) $(SYSTEM_MSBUILD) $(MSBUILD_VERBOSITY_QUIET) xharness/xharness.csproj
|
||||
|
|
|
@ -58,9 +58,18 @@
|
|||
<PackageReference Include="xunit.runner.utility" Version="2.4.1" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Xml" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System">
|
||||
<HintPath>%DOWNLOAD PATH%\System.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Xml">
|
||||
<HintPath>%DOWNLOAD PATH%\System.Xml.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Core">
|
||||
<HintPath>%DOWNLOAD PATH%\System.Core.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Xml.Linq">
|
||||
<HintPath>%DOWNLOAD PATH%\System.Xml.Linq.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Xamarin.Mac" />
|
||||
<Reference Include="xunit.core">
|
||||
<HintPath>..\..\..\external\mono\external\xunit-binaries\xunit.core.dll</HintPath>
|
||||
|
@ -75,12 +84,11 @@
|
|||
<HintPath>..\..\..\external\mono\external\xunit-binaries\xunit.execution.dotnet.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="nunitlite">
|
||||
<HintPath>..\..\..\external\mono\mcs\class\lib\monotouch\nunitlite.dll</HintPath>
|
||||
<HintPath>%DOWNLOAD PATH%\nunitlite.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Xunit.NetCore.Extensions">
|
||||
<HintPath>..\..\..\external\mono\external\xunit-binaries\Xunit.NetCore.Extensions.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
%REFERENCES%
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
# Mono.CSharp.InternalErrorException : (1,1): InteractiveHost
|
||||
# NUnit.Framework.AssertionException : Internal compiler error: Internal compiler error: Internal compiler error: Internal compiler error: The predefined type `Microsoft.CSharp.RuntimeBinder.Binder' is not defined or imported
|
||||
MonoTests.EvaluatorTest.ExpressionsTest.DynamicStatement
|
|
@ -0,0 +1,13 @@
|
|||
# blocks testing app
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadFromPipeWithClosedPartner_ReadNoBytes
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ValidWriteAsync_ValidReadAsync_APM
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadWithZeroLengthBuffer_Nop
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ValidWriteAsync_ValidReadAsync
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadWithZeroLengthBuffer_Nop
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ValidWriteAsync_ValidReadAsync_APM
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ValidWriteAsync_ValidReadAsync
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadFromPipeWithClosedPartner_ReadNoBytes
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.ValidFlush_DoesntThrow
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteZeroLengthBuffer_Nop
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteZeroLengthBuffer_Nop
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.ValidFlush_DoesntThrow
|
|
@ -0,0 +1,4 @@
|
|||
# Timed out after 60000ms waiting for remote process 1536\nExpected: True\nActual: False
|
||||
System.Net.Http.Tests.HttpEnvironmentProxyTest.HttpProxy_EnvironmentProxy_Loaded
|
||||
System.Net.Http.Tests.HttpEnvironmentProxyTest.HttpProxy_CredentialParsing_Basic
|
||||
System.Net.Http.Tests.HttpEnvironmentProxyTest.HttpProxy_Exceptions_Match
|
|
@ -0,0 +1,8 @@
|
|||
# Expected: null
|
||||
# But was: <AppKit.AppKitSynchronizationContext>
|
||||
MonoTests.System.ComponentModel.AsyncOperationManagerTest.SyncContext
|
||||
|
||||
# System.NullReferenceException : Object reference not set to an instance of an object
|
||||
MonoTests.System.Net.NetworkInformation.PingTest.SendAsyncIPV4Fails
|
||||
MonoTests.System.Net.NetworkInformation.PingTest.SendAsyncIPV4Succeeds
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
# blocks app
|
||||
KLASS:System.Net.Tests.SyncWebClientTest
|
||||
KLASS:System.Text.RegularExpressions.Tests.RegexGroupTests
|
||||
KLASS:System.Text.RegularExpressions.Tests.RegexCacheTests
|
||||
KLASS:System.Text.RegularExpressions.Tests.RegexConstructorTests
|
||||
KLASS:System.Net.WebSockets.Tests.WebSocketTests
|
||||
System.Net.WebSockets.Tests.WebSocketTests.ReceiveAsync_ServerSplitHeader_ValidDataReceived
|
||||
System.Net.Tests.WebClientTest.ResponseHeaders_ContainsHeadersAfterOperation
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: null)
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: "text/html; charset=utf-8")
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: "text/html; charset=us-ascii")
|
||||
System.Net.Tests.TaskWebClientTest.DownloadData_Success
|
||||
System.Net.Tests.TaskWebClientTest.DownloadData_LargeData_Success
|
||||
System.Net.Tests.TaskWebClientTest.DownloadFile_Success
|
||||
System.Net.Tests.TaskWebClientTest.OpenRead_Success
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: "text/html; charset=utf-8")
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: null)
|
||||
System.Net.Tests.TaskWebClientTest.DownloadString_Success(contentType: "text/html; charset=us-ascii")
|
||||
System.Text.RegularExpressions.Tests.RegexConstructorTests.Ctor_InvalidPattern(pattern: "?((a)a|", options: None)
|
||||
System.Text.RegularExpressions.Tests.RegexMatchTests.Match_Timeout_Throws
|
||||
System.Text.RegularExpressions.Tests.RegexConstructorTests.StaticCtor_InvalidTimeoutRange_ExceptionThrown
|
||||
RemoteExecutorTests.RemoteInvokeWritesToFile
|
||||
System.Text.RegularExpressions.Tests.RegexMatchTests.Match_ExcessPrefix
|
||||
System.Net.Tests.WebClientTest.RequestHeaders_SpecialHeaders_RequestSucceeds
|
||||
System.Text.RegularExpressions.Tests.RegexMatchTests.Match_SpecialUnicodeCharacters_enUS
|
||||
System.Text.RegularExpressions.Tests.RegexMatchTests.Match_SpecialUnicodeCharacters_Invariant
|
|
@ -0,0 +1,50 @@
|
|||
# System.Security.SecurityException : No access to the given key
|
||||
# ----> System.UnauthorizedAccessException : Access to the path '/Library/Application Support/com.xamarin.bcltests.Mac OS X BCL tests group 3/LocalMachine' is denied.
|
||||
# ----> System.IO.IOException : Permission denied
|
||||
MonoTests.Microsoft.Win32.RegistryKeyTest.OpenSubKey
|
||||
|
||||
# System.IO.FileNotFoundException : Could not load the file 't81'.
|
||||
MonoTests.System.Reflection.Emit.TypeBuilderTest.Ldfld_Encoding_10122
|
||||
|
||||
# #0
|
||||
# Expected: True
|
||||
# But was: False
|
||||
MonoTests.System.Runtime.CompilerServices.AsyncTaskMethodBuilderTest.CallContextFlow
|
||||
|
||||
# An unexpected exception type was thrown
|
||||
# Expected: System.ArgumentNullException
|
||||
# but was: System.TypeLoadException : Can't create an instance of permission class System.DirectoryServices.DirectoryServicesPermission, System.DirectoryServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a.
|
||||
MonoTests.System.Security.Policy.AllMembershipConditionTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.AllMembershipConditionTest.ToXml
|
||||
MonoTests.System.Security.Policy.ApplicationDirectoryMembershipConditionTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.ApplicationDirectoryMembershipConditionTest.ToXml
|
||||
MonoTests.System.Security.Policy.GetMembershipConditionTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.HashMembershipConditionTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.HashMembershipConditionTest.ToXml
|
||||
MonoTests.System.Security.Policy.PolicyStatementTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.GacMembershipConditionTest.FromXml_SecurityElementNull
|
||||
MonoTests.System.Security.Policy.GacMembershipConditionTest.ToXml
|
||||
|
||||
# System.TypeLoadException : Can't create an instance of permission class System.DirectoryServices.DirectoryServicesPermission, System.DirectoryServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a.
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.CreateAppDomainLevel
|
||||
|
||||
# System.TypeLoadException : Can't create an instance of permission class System.DirectoryServices.DirectoryServicesPermission, System.DirectoryServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a.
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Label
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Recover_AppDomainLevel
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Reset
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.ResolveMatchingCodeGroups_Null
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Resolve_Empty
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Resolve_InternetUnrestricted
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Resolve_MyComputerUnrestricted
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.Resolve_Null
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.RootCodeGroup_Null
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.ToXml
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.FromXml_Null
|
||||
MonoTests.System.Security.Policy.PolicyLevelTest.ResolveMatchingCodeGroups_Empty
|
||||
|
||||
# String lengths are both 19. Strings differ at index 12.
|
||||
# Expected: "10/27/2002 03:00:00"
|
||||
# But was: "10/27/2002 02:59:59"
|
||||
MonoTests.System.TimeZoneTest.TestCtors
|
||||
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
# blocks app
|
||||
System.Runtime.CompilerServices.Tests.ConfiguredCancelableAsyncEnumerableTests.CanBeEnumeratedWithStandardPattern
|
|
@ -0,0 +1,54 @@
|
|||
# System.PlatformNotSupportedException : Operation is not supported on this platform.
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_CreateClient.CreateClientStreamFromStringHandle_Valid
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_CreateServer.ValidConstructors
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_CreateServer.InOutPipeDirection_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_CreateServer.InvalidPipeHandle_Throws
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadOnDisposedReadablePipe_Throws_ObjectDisposedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadWithNegativeCount_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.WriteToReadOnlyPipe_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.CopyToAsync_InvalidArgs_Throws
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadWithNullBuffer_Throws_ArgumentNullException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ValidWrite_ValidRead: System.PlatformNotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadWithOutOfBoundsArray_Throws_ArgumentException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ValidWriteByte_ValidReadByte
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadWithNegativeOffset_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ReadPipeUnsupportedMembers_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadOnDisposedReadablePipe_Throws_ObjectDisposedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ValidWriteByte_ValidReadByte
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadWithNegativeCount_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.CopyToAsync_InvalidArgs_Throws: System.PlatformNotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadWithOutOfBoundsArray_Throws_ArgumentException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ValidWrite_ValidRead
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.WriteToReadOnlyPipe_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadWithNullBuffer_Throws_ArgumentNullException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadPipeUnsupportedMembers_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.ReadWithNegativeOffset_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.InvalidReadMode_Throws_ArgumentOutOfRangeException: System.PlatformNotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.ReadModeToByte_Accepted(serverDirection: In, clientDirection: Out)
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.ReadModeToByte_Accepted(serverDirection: Out, clientDirection: In)
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.ClonedServer_ActsAsOriginalServer
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.MessageReadMode_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.DisposeLocalCopyOfClientHandle_BeforeServerRead
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.DisposeLocalCopyOfClientHandle_BeforeServerRead
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.PipeTransmissionMode_Returns_Byte
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.ClonedClient_ActsAsOriginalClient
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteWithNegativeCount_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteWithNegativeOffset_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WritePipeUnsupportedMembers_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.ReadOnWriteOnlyPipe_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteWithNullBuffer_Throws_ArgumentNullException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteWithOutOfBoundsArray_Throws_ArgumentException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteToPipeWithClosedPartner_Throws_IOException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerIn_ClientOut.WriteToDisposedWriteablePipe_Throws_ObjectDisposedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteWithNegativeCount_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteWithNullBuffer_Throws_ArgumentNullException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteToDisposedWriteablePipe_Throws_ObjectDisposedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteWithOutOfBoundsArray_Throws_ArgumentException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.ReadOnWriteOnlyPipe_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WritePipeUnsupportedMembers_Throws_NotSupportedException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteToPipeWithClosedPartner_Throws_IOException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Write_ServerOut_ClientIn.WriteWithNegativeOffset_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerIn_ClientOut.ValidWrite_ValidRead
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Read_ServerOut_ClientIn.CopyToAsync_InvalidArgs_Throws
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.InvalidReadMode_Throws_ArgumentOutOfRangeException
|
||||
System.IO.Pipes.Tests.AnonymousPipeTest_Specific.OSX_BufferSizeNotSupported
|
|
@ -0,0 +1,3 @@
|
|||
# System.PlatformNotSupportedException
|
||||
KLASS:System.IO.Tests.FileSystemWatcherTests_netstandard17
|
||||
KLASS:System.IO.Tests.FileSystemWatcherTests
|
|
@ -23,6 +23,7 @@ namespace xharness.BCLTestImporter {
|
|||
|
||||
projectGenerator = new BCLTestProjectGenerator (outputDir, Harness.MONO_PATH, projectTemplatePath, registerTypesTemplatePath, plistTemplatePath) {
|
||||
iOSMonoSDKPath = Harness.MONO_IOS_SDK_DESTDIR,
|
||||
MacMonoSDKPath = Harness.MONO_MAC_SDK_DESTDIR,
|
||||
Override = true,
|
||||
GuidGenerator = Harness.NewStableGuid,
|
||||
GroupTests = Harness.InJenkins || Harness.UseGroupedApps,
|
||||
|
@ -64,11 +65,6 @@ namespace xharness.BCLTestImporter {
|
|||
IsExecutableProject = true,
|
||||
FailureMessage = failure,
|
||||
RestoreNugetsInProject = true,
|
||||
Dependency = async () => {
|
||||
var rv = await Harness.BuildBclTests ();
|
||||
if (!rv.Succeeded)
|
||||
throw new Exception ($"Failed to build BCL tests, exit code: {rv.ExitCode}. Check the harness log for more details.");
|
||||
}
|
||||
});
|
||||
}
|
||||
return result;
|
||||
|
|
|
@ -886,14 +886,6 @@ namespace xharness
|
|||
return rv;
|
||||
}
|
||||
|
||||
Task<ProcessExecutionResult> build_bcl_tests;
|
||||
public Task<ProcessExecutionResult> BuildBclTests ()
|
||||
{
|
||||
if (build_bcl_tests == null)
|
||||
build_bcl_tests = ProcessHelper.ExecuteCommandAsync ("make", $".stamp-build-mono-unit-tests -C {StringUtils.Quote (Path.GetFullPath (RootDirectory))}", HarnessLog, TimeSpan.FromMinutes (30));
|
||||
return build_bcl_tests;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public class CrashReportSnapshot
|
||||
|
|
|
@ -133,9 +133,6 @@
|
|||
<Compile Include="..\..\tools\bcl-test-importer\BCLTestImporter\BCLTestInfoPlistGenerator.cs">
|
||||
<Link>BCLTestImporter\BCLTestInfoPlistGenerator.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="..\..\tools\bcl-test-importer\BCLTestImporter\BCLTestProjectDefinitionWorkaround.cs">
|
||||
<Link>BCLTestImporter\BCLTestProjectDefinitionWorkaround.cs</Link>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Folder Include="BCLTestImporter\" />
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
using System;
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Collections.Generic;
|
||||
|
||||
|
@ -8,13 +8,19 @@ namespace BCLTestImporter {
|
|||
#region static vars
|
||||
|
||||
static string partialPath = "mcs/class/lib";
|
||||
static string downloadPartialPath = "ios-bcl";
|
||||
static Dictionary <Platform, string> platformPathMatch = new Dictionary <Platform, string> {
|
||||
static readonly Dictionary<Platform, string> downloadPartialPath = new Dictionary<Platform, string> {
|
||||
{Platform.iOS, "ios-bcl"},
|
||||
{Platform.WatchOS, "ios-bcl"},
|
||||
{Platform.TvOS, "ios-bcl"},
|
||||
{Platform.MacOSFull, "mac-bcl"},
|
||||
{Platform.MacOSModern, "mac-bcl"},
|
||||
};
|
||||
static readonly Dictionary <Platform, string> platformPathMatch = new Dictionary <Platform, string> {
|
||||
{Platform.iOS, "monotouch"},
|
||||
{Platform.WatchOS, "monotouch_watch"},
|
||||
{Platform.TvOS, "monotouch_tv"},
|
||||
{Platform.MacOSFull, "xammac_net_4_5"},
|
||||
{Platform.MacOSModern, "xammac_net_4_5"},
|
||||
{Platform.MacOSModern, "xammac"},
|
||||
};
|
||||
#endregion
|
||||
|
||||
|
@ -40,6 +46,8 @@ namespace BCLTestImporter {
|
|||
return Name.Replace ("monotouch_", "monotouch_watch_");
|
||||
case Platform.TvOS:
|
||||
return Name.Replace ("monotouch_", "monotouch_tv_");
|
||||
case Platform.MacOSModern:
|
||||
return Name.Replace ("xammac_net_4_5", "xammac");
|
||||
default:
|
||||
return Name;
|
||||
}
|
||||
|
@ -70,17 +78,28 @@ namespace BCLTestImporter {
|
|||
{
|
||||
if (string.IsNullOrEmpty (downloadsPath))
|
||||
throw new ArgumentNullException (nameof (downloadsPath));
|
||||
return Path.Combine (downloadsPath, "ios-bcl", platformPathMatch [platform], "tests");
|
||||
|
||||
switch (platform) {
|
||||
case Platform.MacOSFull:
|
||||
case Platform.MacOSModern:
|
||||
return Path.Combine (downloadsPath, "mac-bcl", platformPathMatch [platform], "tests");
|
||||
case Platform.iOS:
|
||||
case Platform.TvOS:
|
||||
case Platform.WatchOS:
|
||||
return Path.Combine (downloadsPath, "ios-bcl", platformPathMatch [platform], "tests");
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
public static string GetHintPathForRefenreceAssembly (string assembly, string monoRootPath, Platform plaform, bool isDownload)
|
||||
public static string GetHintPathForRefenreceAssembly (string assembly, string monoRootPath, Platform platform, bool isDownload)
|
||||
{
|
||||
var hintPath = Path.Combine (monoRootPath, isDownload? downloadPartialPath : partialPath, platformPathMatch[plaform], $"{assembly}.dll");
|
||||
var hintPath = Path.Combine (monoRootPath, isDownload? downloadPartialPath [platform] : partialPath, platformPathMatch [platform], $"{assembly}.dll");
|
||||
if (File.Exists (hintPath)) {
|
||||
return hintPath;
|
||||
} else {
|
||||
// we could be referencing a dll in the test dir, lets test that
|
||||
hintPath = Path.Combine (monoRootPath, isDownload? downloadPartialPath : partialPath, platformPathMatch[plaform], "tests", $"{assembly}.dll");
|
||||
hintPath = Path.Combine (monoRootPath, isDownload? downloadPartialPath [platform] : partialPath, platformPathMatch [platform], "tests", $"{assembly}.dll");
|
||||
}
|
||||
return File.Exists (hintPath) ? hintPath : null;
|
||||
}
|
||||
|
|
|
@ -40,7 +40,6 @@
|
|||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="BCLTestInfoPlistGenerator.cs" />
|
||||
<Compile Include="BCLTestProjectDefinitionWorkaround.cs" />
|
||||
<Compile Include="Platform.cs" />
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="RegisterTypeGenerator.cs" />
|
||||
|
|
|
@ -1,332 +0,0 @@
|
|||
using System;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace BCLTestImporter
|
||||
{
|
||||
// Added for the workaround so that it does not make the code uglier
|
||||
public partial struct BCLTestProjectDefinition
|
||||
{
|
||||
|
||||
internal static Dictionary<string, List<(string assembly, string hint)>> MacCachedAssemblyInfo =
|
||||
new Dictionary<string, List<(string assembly, string hint)>> {
|
||||
{"MonoCSharpTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"Mono.CSharp", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.CSharp.dll"),
|
||||
(assembly:"Microsoft.CSharp", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Microsoft.CSharp.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_Mono.CSharp_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Mono.CSharp_test.dll"),
|
||||
}},
|
||||
{"MonoDataSqliteTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"Mono.Data.Sqlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Data.Sqlite.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_Mono.Data.Sqlite_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Mono.Data.Sqlite_test.dll"),
|
||||
}},
|
||||
{"MonoDataTdsTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"Mono.Data.Tds", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Data.Tds.dll"),
|
||||
(assembly:"xammac_net_4_5_Mono.Data.Tds_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Mono.Data.Tds_test.dll"),
|
||||
}},
|
||||
{"MonoPoxisTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"Mono.Posix", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Posix.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_Mono.Posix_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Mono.Posix_test.dll"),
|
||||
}},
|
||||
{"MonoSecurityTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"Mono.Security", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Security.dll"),
|
||||
(assembly:"xammac_net_4_5_Mono.Security_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Mono.Security_test.dll"),
|
||||
}},
|
||||
{"SystemComponentModelDataAnnotationsTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.ComponentModel.DataAnnotations", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.ComponentModel.DataAnnotations.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_System.ComponentModel.DataAnnotations_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.ComponentModel.DataAnnotations_test.dll"),
|
||||
}},
|
||||
{"SystemConfigurationTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Configuration", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Configuration.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Configuration_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Configuration_test.dll"),
|
||||
}},
|
||||
{"SystemCoreTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Core_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Core_test.dll"),
|
||||
}},
|
||||
{"SystemDataLinqTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Data.Linq", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.Linq.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Data.Linq_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Data.Linq_test.dll"),
|
||||
}},
|
||||
{"SystemDataTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Configuration", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Configuration.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"Mono.Data.Sqlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Data.Sqlite.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Data_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Data_test.dll"),
|
||||
}},
|
||||
{"SystemIOCompressionFileSystemTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.IO.Compression", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.IO.Compression.dll"),
|
||||
(assembly:"System.IO.Compression.FileSystem", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.IO.Compression.FileSystem.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_System.IO.Compression.FileSystem_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.IO.Compression.FileSystem_test.dll"),
|
||||
}},
|
||||
{"SystemIOCompressionTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.IO.Compression", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.IO.Compression.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.IO.Compression_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.IO.Compression_test.dll"),
|
||||
}},
|
||||
{"SystemIdentityModelTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.IdentityModel", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.IdentityModel.dll"),
|
||||
(assembly:"System.Runtime.Serialization", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Runtime.Serialization.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"xammac_net_4_5_System.IdentityModel_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.IdentityModel_test.dll"),
|
||||
}},
|
||||
{"SystemJsonTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Json", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Json.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Json_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Json_test.dll"),
|
||||
}},
|
||||
{"SystemNetHttpTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Net.Http", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Net.Http.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Net.Http_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Net.Http_test.dll"),
|
||||
}},
|
||||
{"SystemNumericsTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Numerics", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Numerics.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Numerics_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Numerics_test.dll"),
|
||||
}},
|
||||
{"SystemRuntimeSerializationFormattersSoapTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Runtime.Serialization.Formatters.Soap", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Runtime.Serialization.Formatters.Soap.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Runtime.Serialization.Formatters.Soap_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Runtime.Serialization.Formatters.Soap_test.dll"),
|
||||
}},
|
||||
{"SystemSecurityTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Security", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Security.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Security_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Security_test.dll"),
|
||||
}},
|
||||
{"SystemServiceModelTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.ServiceModel", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.ServiceModel.dll"),
|
||||
(assembly:"System.Runtime.Serialization", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Runtime.Serialization.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.IdentityModel", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.IdentityModel.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System.Security", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Security.dll"),
|
||||
(assembly:"xammac_net_4_5_System.ServiceModel_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.ServiceModel_test.dll"),
|
||||
}},
|
||||
{"SystemTransactionsTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Transactions", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Transactions.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Transactions_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Transactions_test.dll"),
|
||||
}},
|
||||
{"SystemXmlLinqTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"System.Xml.Linq", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.Linq.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Xml.Linq_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Xml.Linq_test.dll"),
|
||||
}},
|
||||
{"SystemXmlTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Xml_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Xml_test.dll"),
|
||||
}},
|
||||
{"SystemTests", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"nunitlite", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/nunitlite.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"System.Configuration", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Configuration.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"Mono.Security", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Mono.Security.dll"),
|
||||
(assembly:"xammac_net_4_5_System_test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System_test.dll"),
|
||||
}},
|
||||
{"MicrosoftCSharpXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"Microsoft.CSharp", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Microsoft.CSharp.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"xammac_net_4_5_Microsoft.CSharp_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_Microsoft.CSharp_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemCoreXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"Microsoft.CSharp", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Microsoft.CSharp.dll"),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"xunit.execution.dotnet", hint:""),
|
||||
(assembly:"xammac_net_4_5_System.Core_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Core_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemDataXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System.Data", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Data.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Data_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Data_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemJsonXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System.Json", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Json.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Json_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Json_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemNumericsXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System.Numerics", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Numerics.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"Microsoft.CSharp", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/Microsoft.CSharp.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Numerics_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Numerics_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemRuntimeCompilerServicesUnsafeXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System.Runtime.CompilerServices.Unsafe", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Runtime.CompilerServices.Unsafe.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"xammac_net_4_5_System.Runtime.CompilerServices.Unsafe_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Runtime.CompilerServices.Unsafe_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemSecurityXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System.Security", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Security.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Security_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Security_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemXmlLinqXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"System.Xml", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System.Xml.Linq", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Xml.Linq.dll"),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System.Xml.Linq_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System.Xml.Linq_xunit-test.dll"),
|
||||
}},
|
||||
{"SystemXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"xammac_net_4_5_System_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_System_xunit-test.dll"),
|
||||
}},
|
||||
{"CorlibXunit", new List<(string assembly, string hint)> {
|
||||
(assembly:"mscorlib", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/mscorlib.dll"),
|
||||
(assembly:"xunit.core", hint:""),
|
||||
(assembly:"xunit.abstractions", hint:""),
|
||||
(assembly:"Xunit.NetCore.Extensions", hint:"{MONO_ROOT}external/xunit-binaries/Xunit.NetCore.Extensions.dll"),
|
||||
(assembly:"xunit.assert", hint:""),
|
||||
(assembly:"System", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.dll"),
|
||||
(assembly:"System.Core", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Core.dll"),
|
||||
(assembly:"System.Numerics", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Numerics.dll"),
|
||||
(assembly:"System.Runtime.CompilerServices.Unsafe", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/System.Runtime.CompilerServices.Unsafe.dll"),
|
||||
(assembly:"xammac_net_4_5_corlib_xunit-test.dll", hint:"{MONO_ROOT}mcs/class/lib/xammac_net_4_5/tests/xammac_net_4_5_corlib_xunit-test.dll"),
|
||||
}},
|
||||
};
|
||||
public List<(string assembly, string hintPath)> GetCachedAssemblyInclusionInformation (string monoRootPath,
|
||||
Platform platform)
|
||||
{
|
||||
if (!monoRootPath.EndsWith ("/", StringComparison.Ordinal))
|
||||
monoRootPath += "/";
|
||||
var info = new List<(string assembly, string hintPath)> ();
|
||||
switch (platform){
|
||||
case Platform.iOS:
|
||||
case Platform.TvOS:
|
||||
case Platform.WatchOS:
|
||||
throw new InvalidOperationException ("All iOS platforms must used the dlls from the SDK and not build their own tests.");
|
||||
case Platform.MacOSFull:
|
||||
case Platform.MacOSModern:
|
||||
info = MacCachedAssemblyInfo[Name];
|
||||
break;
|
||||
}
|
||||
// lets fix the path
|
||||
var fixedResult = new List<(string assembly, string hintPath)> ();
|
||||
foreach (var (assembly, hin) in info){
|
||||
fixedResult.Add ((assembly, hin.Replace ("{MONO_ROOT}", monoRootPath)));
|
||||
}
|
||||
|
||||
return fixedResult;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -163,22 +163,28 @@ namespace BCLTestImporter {
|
|||
// NUNIT Projects
|
||||
(name:"MonoDataSqliteTests", assemblies: new [] {"xammac_net_4_5_Mono.Data.Sqlite_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"MonoDataTdsTests", assemblies: new [] {"xammac_net_4_5_Mono.Data.Tds_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"MonoMessagingTests", assemblies: new [] {"xammac_net_4_5_Mono.Messaging_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"MonoPoxisTests", assemblies: new [] {"xammac_net_4_5_Mono.Posix_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"MonoSecurityTests", assemblies: new [] {"xammac_net_4_5_Mono.Security_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemConfigurationTests", assemblies: new [] {"xammac_net_4_5_System.Configuration_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemDataLinqTests", assemblies: new [] {"xammac_net_4_5_System.Data.Linq_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemDataTests", assemblies: new [] {"xammac_net_4_5_System.Data_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemIOCompressionFileSystemTests", assemblies: new [] {"xammac_net_4_5_System.IO.Compression.FileSystem_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemIOCompressionTests", assemblies: new [] {"xammac_net_4_5_System.IO.Compression_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemIdentityModelTests", assemblies: new [] {"xammac_net_4_5_System.IdentityModel_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemJsonTests", assemblies: new [] {"xammac_net_4_5_System.Json_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemNetHttpTests", assemblies: new [] {"xammac_net_4_5_System.Net.Http_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemMessagingTests", assemblies: new [] {"xammac_net_4_5_System.Messaging_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemNetHttpWebRequestTests", assemblies: new [] {"xammac_net_4_5_System.Net.Http.WebRequest_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemNumericsTests", assemblies: new [] {"xammac_net_4_5_System.Numerics_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemRuntimeSerializationFormattersSoapTests", assemblies: new [] {"xammac_net_4_5_System.Runtime.Serialization.Formatters.Soap_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemRuntimeSerializationTests", assemblies: new [] {"xammac_net_4_5_System.Runtime.Serialization_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemServiceModelWebTest", assemblies: new [] {"xammac_net_4_5_System.ServiceModel.Web_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemServiceModelTests", assemblies: new [] {"xammac_net_4_5_System.ServiceModel_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemTransactionsTests", assemblies: new [] {"xammac_net_4_5_System.Transactions_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemWebServicesTests", assemblies: new [] {"xammac_net_4_5_System.Web.Services_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemXmlLinqTests", assemblies: new [] {"xammac_net_4_5_System.Xml.Linq_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemConfigurationTests", assemblies: new [] {"xammac_net_4_5_System.Configuration_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
(name:"SystemDataTests", assemblies: new [] {"xammac_net_4_5_System.Data_test.dll"}, group: "Mac OS X BCL tests group 1"),
|
||||
|
||||
|
||||
(name:"SystemNetHttpTests", assemblies: new [] {"xammac_net_4_5_System.Net.Http_test.dll"}, group: "Mac OS X BCL tests group 2"), // do not mix with SystemNetHttpWebRequestTests since there is a type collision
|
||||
(name:"SystemComponentModelDataAnnotationsTests", assemblies: new [] {"xammac_net_4_5_System.ComponentModel.DataAnnotations_test.dll"}, group: "Mac OS X BCL tests group 2"),
|
||||
(name:"SystemCoreTests", assemblies: new [] {"xammac_net_4_5_System.Core_test.dll"}, group: "Mac OS X BCL tests group 2"),
|
||||
(name:"SystemSecurityTests", assemblies: new [] {"xammac_net_4_5_System.Security_test.dll"}, group: "Mac OS X BCL tests group 2"),
|
||||
|
@ -186,34 +192,43 @@ namespace BCLTestImporter {
|
|||
(name:"SystemTests", assemblies: new [] {"xammac_net_4_5_System_test.dll"}, group: "Mac OS X BCL tests group 2"),
|
||||
(name:"MonoCSharpTests", assemblies: new [] {"xammac_net_4_5_Mono.CSharp_test.dll"}, group: "Mac OS X BCL tests group 2"), // if add to the first group, it blocks 'til a timeout, mono issue
|
||||
|
||||
(name:"CorlibTests", assemblies: new [] {"xammac_net_4_5_corlib_test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
|
||||
// xUnit Projects
|
||||
(name:"MicrosoftCSharpXunit", assemblies: new [] {"xammac_net_4_5_Microsoft.CSharp_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemCoreXunit", assemblies: new [] {"xammac_net_4_5_System.Core_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemDataXunit", assemblies: new [] {"xammac_net_4_5_System.Data_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemJsonXunit", assemblies: new [] {"xammac_net_4_5_System.Json_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemNumericsXunit", assemblies: new [] {"xammac_net_4_5_System.Numerics_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemRuntimeCompilerServicesUnsafeXunit", assemblies: new [] {"xammac_net_4_5_System.Runtime.CompilerServices.Unsafe_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemSecurityXunit", assemblies: new [] {"xammac_net_4_5_System.Security_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemXmlLinqXunit", assemblies: new [] {"xammac_net_4_5_System.Xml.Linq_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"SystemXunit", assemblies: new [] {"xammac_net_4_5_System_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"CorlibXunit", assemblies: new [] {"xammac_net_4_5_corlib_xunit-test.dll"}, group: "Mac OS X BCL tests group 3"),
|
||||
(name:"MicrosoftCSharpXunit", assemblies: new [] {"xammac_net_4_5_Microsoft.CSharp_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemComponentModelCompositionXunit", assemblies: new [] {"xammac_net_4_5_System.ComponentModel.Composition_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemCoreXunit", assemblies: new [] {"xammac_net_4_5_System.Core_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemDataXunit", assemblies: new [] {"xammac_net_4_5_System.Data_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemJsonXunit", assemblies: new [] {"xammac_net_4_5_System.Json_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemNetHttpFunctionalTestsXunit", assemblies: new [] {"xammac_net_4_5_System.Net.Http.FunctionalTests_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemNetHttpUnitTestsXunit", assemblies: new [] {"xammac_net_4_5_System.Net.Http.UnitTests_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemNumericsXunit", assemblies: new [] {"xammac_net_4_5_System.Numerics_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemRuntimeCompilerServicesUnsafeXunit", assemblies: new [] {"xammac_net_4_5_System.Runtime.CompilerServices.Unsafe_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemSecurityXunit", assemblies: new [] {"xammac_net_4_5_System.Security_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemXmlLinqXunit", assemblies: new [] {"xammac_net_4_5_System.Xml.Linq_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemXmlXunit", assemblies: new [] {"xammac_net_4_5_System.Xml_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
(name:"SystemXunit", assemblies: new [] {"xammac_net_4_5_System_xunit-test.dll"}, group: "Mac OS X BCL tests group 4"),
|
||||
|
||||
(name:"CorlibXunit", assemblies: new [] {"xammac_net_4_5_corlib_xunit-test.dll"}, group: "Mac OS X BCL tests group 5"),
|
||||
|
||||
};
|
||||
|
||||
static readonly List<(string assembly, Platform[] platforms)> macIgnoredAssemblies = new List<(string assembly, Platform[] platforms)> {
|
||||
(assembly: "xammac_net_4_5_corlib_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // exception when loading the image via refection
|
||||
(assembly: "xammac_net_4_5_I18N.CJK_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }),
|
||||
(assembly: "xammac_net_4_5_I18N.MidEast_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }),
|
||||
(assembly: "xammac_net_4_5_I18N.Other_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }),
|
||||
(assembly: "xammac_net_4_5_I18N.Rare_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }),
|
||||
(assembly: "xammac_net_4_5_I18N.West_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }),
|
||||
(assembly: "xammac_net_4_5_System.Runtime.Serialization.Formatters.Soap_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_System.Net.Http.WebRequest_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_System.Messaging_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_System.IdentityModel_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_System.Data.Linq_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_Mono.Posix_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_Mono.Messaging_test.dll", platforms: new [] { Platform.MacOSModern}), // not present
|
||||
(assembly: "xammac_net_4_5_System.Data_test.dll", platforms: new [] { Platform.MacOSModern }), // tests use 'System.Configuration.IConfigurationSectionHandler' not present in modern
|
||||
(assembly: "xammac_net_4_5_System_test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // issues https://github.com/xamarin/maccore/issues/1199
|
||||
(assembly: "xammac_net_4_5_System.Xml_test.dll", platforms: new [] { Platform.MacOSModern }), // ignored in modern because tests use System.Xml.Serialization.Advanced.SchemaImporterExtension
|
||||
(assembly: "xammac_net_4_5_corlib_xunit-test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // issues https://github.com/xamarin/maccore/issues/1203
|
||||
(assembly: "xammac_net_4_5_System.Core_xunit-test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // issue https://github.com/xamarin/maccore/issues/1204
|
||||
(assembly: "xammac_net_4_5_System_xunit-test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // issue https://github.com/xamarin/maccore/issues/1209
|
||||
(assembly: "xammac_net_4_5_System.Configuration_test.dll", platforms: new [] { Platform.MacOSModern }), // Not present in modern, ergo all tests will fail
|
||||
(assembly: "xammac_net_4_5_System.Security_xunit-test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // https://github.com/xamarin/maccore/issues/1243
|
||||
(assembly: "xammac_net_4_5_corlib_xunit-test.dll", platforms: new [] { Platform.MacOSFull, Platform.MacOSModern }), // issues https://github.com/xamarin/maccore/issues/1203
|
||||
};
|
||||
|
||||
readonly bool isCodeGeneration;
|
||||
|
@ -222,6 +237,7 @@ namespace BCLTestImporter {
|
|||
public string OutputDirectoryPath { get; private set; }
|
||||
public string MonoRootPath { get; private set; }
|
||||
public string iOSMonoSDKPath { get; set; }
|
||||
public string MacMonoSDKPath { get; set; }
|
||||
public string ProjectTemplateRootPath { get; private set; }
|
||||
public string PlistTemplateRootPath{ get; private set; }
|
||||
public string RegisterTypesTemplatePath { get; private set; }
|
||||
|
@ -256,7 +272,7 @@ namespace BCLTestImporter {
|
|||
return iOSMonoSDKPath;
|
||||
case Platform.MacOSFull:
|
||||
case Platform.MacOSModern:
|
||||
return null;
|
||||
return MacMonoSDKPath;
|
||||
default:
|
||||
return null;
|
||||
}
|
||||
|
@ -385,7 +401,7 @@ namespace BCLTestImporter {
|
|||
case Platform.MacOSFull:
|
||||
return new string [] { $"macOSFull-{name}.ignore", $"macOS-{name}.ignore" };
|
||||
case Platform.MacOSModern:
|
||||
return new string [] { $"macOSModern-{name}.ignore", $"macOS-{name}.ignore" };
|
||||
return new string [] { $"macOSModern-{name.Replace ("xammac_", "xammac_net_4_5_")}.ignore", $"macOS-{name.Replace ("xammac_", "xammac_net_4_5_")}.ignore" };
|
||||
case Platform.TvOS:
|
||||
return new string [] { $"tvOS-{name.Replace ("monotouch_tv_", "monotouch_")}.ignore" };
|
||||
case Platform.WatchOS:
|
||||
|
@ -618,6 +634,8 @@ namespace BCLTestImporter {
|
|||
{
|
||||
var projectPaths = new List<(string name, string path, bool xunit, string failure)> ();
|
||||
foreach (var def in projects) {
|
||||
if (!def.assemblies.Any ())
|
||||
continue;
|
||||
var projectDefinition = new BCLTestProjectDefinition (def.name, def.assemblies);
|
||||
if (IsIgnored (projectDefinition, platform)) // some projects are ignored, so we just continue
|
||||
continue;
|
||||
|
@ -629,8 +647,9 @@ namespace BCLTestImporter {
|
|||
Directory.CreateDirectory (generatedCodeDir);
|
||||
var registerTypePath = Path.Combine (generatedCodeDir, "RegisterType-mac.cs");
|
||||
|
||||
var registerCode = await RegisterTypeGenerator.GenerateCodeAsync (def.name, projectDefinition.IsXUnit,
|
||||
RegisterTypesTemplatePath, platform);
|
||||
var typesPerAssembly = projectDefinition.GetTypeForAssemblies (GetReleaseDownload (platform), platform, true);
|
||||
var registerCode = await RegisterTypeGenerator.GenerateCodeAsync (typesPerAssembly,
|
||||
projectDefinition.IsXUnit, RegisterTypesTemplatePath);
|
||||
|
||||
using (var file = new StreamWriter (registerTypePath, false)) { // false is do not append
|
||||
await file.WriteAsync (registerCode);
|
||||
|
@ -644,8 +663,10 @@ namespace BCLTestImporter {
|
|||
}
|
||||
|
||||
var projectTemplatePath = Path.Combine (ProjectTemplateRootPath, projectTemplateMatches[platform]);
|
||||
var info = projectDefinition.GetAssemblyInclusionInformation (GetReleaseDownload (platform), platform, true);
|
||||
var generatedProject = await GenerateMacAsync (projectDefinition.Name, registerTypePath,
|
||||
projectDefinition.GetCachedAssemblyInclusionInformation (MonoRootPath, platform), projectTemplatePath, infoPlistPath, platform);
|
||||
info, projectTemplatePath, infoPlistPath, platform);
|
||||
|
||||
var projectPath = GetProjectPath (projectDefinition.Name, platform);
|
||||
projectPaths.Add ((name: projectDefinition.Name, path: projectPath, xunit: projectDefinition.IsXUnit, failure: null));
|
||||
using (var file = new StreamWriter (projectPath, false)) { // false is do not append
|
||||
|
@ -768,39 +789,6 @@ namespace BCLTestImporter {
|
|||
if (!Directory.Exists (generatedCodePathRoot)) {
|
||||
Directory.CreateDirectory (generatedCodePathRoot);
|
||||
}
|
||||
if (GroupTests) {
|
||||
// special case until we have the support to add reflection on Mac OS X that depends on the download of the Mono SDK. Get the info
|
||||
// from the cache, but since we are grouping, we have to ensure that we do not add the info for the projects that have to be ignored
|
||||
var projectsHints = new Dictionary<string, List<(string assembly, string hint)>> ();
|
||||
var projectTypes = new Dictionary<string, List<(string testNamespace, string testAssembly, string testType)>> ();
|
||||
foreach (var (name, assemblies, group) in macTestProjects) {
|
||||
var filteredAssemblies = new List<(string assembly, string hint)> (BCLTestProjectDefinition.MacCachedAssemblyInfo [name]);
|
||||
foreach (var assemblyHint in BCLTestProjectDefinition.MacCachedAssemblyInfo [name]) {
|
||||
if (IsIgnored (assemblyHint.assembly, platform))
|
||||
filteredAssemblies.Remove (assemblyHint);
|
||||
}
|
||||
if (projectsHints.ContainsKey (group)) {
|
||||
projectsHints [group].AddRange (filteredAssemblies);
|
||||
} else {
|
||||
projectsHints [group] = new List<(string assembly, string hint)> (filteredAssemblies);
|
||||
}
|
||||
var filteredType = new List<(string testNamespace, string testAssembly, string testType)> (RegisterTypeGenerator.MacCache [name]);
|
||||
foreach (var typeRegistration in RegisterTypeGenerator.MacCache [name]) {
|
||||
if (IsIgnored (typeRegistration.testAssembly, platform))
|
||||
filteredType.Remove (typeRegistration);
|
||||
}
|
||||
if (projectTypes.ContainsKey (group)) {
|
||||
projectTypes [group].AddRange (filteredType);
|
||||
} else {
|
||||
projectTypes [group] = new List<(string testNamespace, string testAssembly, string testType)> (filteredType);
|
||||
}
|
||||
}
|
||||
// add them to the caches, they have the same keys
|
||||
foreach (var groupName in projectsHints.Keys) {
|
||||
BCLTestProjectDefinition.MacCachedAssemblyInfo [groupName] = projectsHints [groupName];
|
||||
RegisterTypeGenerator.MacCache [groupName] = projectTypes [groupName].ToArray ();
|
||||
}
|
||||
}
|
||||
var generated = await GenerateTestProjectsAsync (GetProjectDefinitions (macTestProjects, platform), platform, generatedCodePathRoot);
|
||||
return generated;
|
||||
}
|
||||
|
@ -850,22 +838,28 @@ namespace BCLTestImporter {
|
|||
}
|
||||
}
|
||||
|
||||
async Task<string> GenerateMacAsync (string projectName, string registerPath, List<(string assembly, string hintPath)> info, string templatePath, string infoPlistPath, Platform platform)
|
||||
async Task<string> GenerateMacAsync (string projectName, string registerPath, (string FailureMessage, List<(string assembly, string hintPath)> Assemblies) info, string templatePath, string infoPlistPath, Platform platform)
|
||||
{
|
||||
var downloadPath = Path.Combine(GetReleaseDownload (platform), "mac-bcl", platform == Platform.MacOSFull? "xammac_net_4_5" : "xammac").Replace ("/", "\\");
|
||||
infoPlistPath = infoPlistPath.Replace ('/', '\\');
|
||||
var sb = new StringBuilder ();
|
||||
foreach (var assemblyInfo in info) {
|
||||
if (!excludeDlls.Contains (assemblyInfo.assembly))
|
||||
sb.AppendLine (GetReferenceNode (assemblyInfo.assembly, assemblyInfo.hintPath));
|
||||
if (!string.IsNullOrEmpty (info.FailureMessage)) {
|
||||
WriteReferenceFailure (sb, info.FailureMessage);
|
||||
} else {
|
||||
foreach (var assemblyInfo in info.Assemblies) {
|
||||
if (!excludeDlls.Contains (assemblyInfo.assembly))
|
||||
sb.AppendLine (GetReferenceNode (assemblyInfo.assembly, assemblyInfo.hintPath));
|
||||
}
|
||||
}
|
||||
|
||||
var contentFiles = new StringBuilder ();
|
||||
foreach (var path in GetIgnoreFiles (templatePath, projectName, info, platform)) {
|
||||
foreach (var path in GetIgnoreFiles (templatePath, projectName, info.Assemblies, platform)) {
|
||||
contentFiles.Append (GetContentNode (path));
|
||||
}
|
||||
var projectGuid = GuidGenerator?.Invoke (projectName) ?? Guid.NewGuid ();
|
||||
using (var reader = new StreamReader(templatePath)) {
|
||||
var result = await reader.ReadToEndAsync ();
|
||||
result = result.Replace (DownloadPathKey, downloadPath);
|
||||
result = result.Replace (ProjectGuidKey, projectGuid.ToString ().ToUpperInvariant ());
|
||||
result = result.Replace (NameKey, projectName);
|
||||
result = result.Replace (ReferencesKey, sb.ToString ());
|
||||
|
|
|
@ -13,73 +13,6 @@ namespace BCLTestImporter {
|
|||
static readonly string KeysReplacement = "%KEY VALUES%";
|
||||
static readonly string IsxUnitReplacement = "%IS XUNIT%";
|
||||
|
||||
// the following cache is a workaround until mono does provide the required binaries precompiled, at that point
|
||||
// we will remove the dict and we will use the refection based method.
|
||||
internal static Dictionary<string, (string testNamespace, string testAssembly, string testType) []> MacCache = new Dictionary<string, (string testNamespace, string testAssembly, string testType) []> {
|
||||
{"MonoCSharpTests", new [] {("MonoTests.Visit", "xammac_net_4_5_Mono.CSharp_test.dll", "MonoTests.Visit.ASTVisitorTest")} },
|
||||
{"MonoDataSqliteTests", new [] {("MonoTests.Mono.Data.Sqlite", "xammac_net_4_5_Mono.Data.Sqlite_test.dll", "MonoTests.Mono.Data.Sqlite.SqliteiOS82BugTests")}},
|
||||
{"MonoDataTdsTests", new [] {("MonoTests.Mono.Data.Tds", "xammac_net_4_5_Mono.Data.Tds_test.dll", "MonoTests.Mono.Data.Tds.TdsConnectionPoolTest")}},
|
||||
{"MonoPoxisTests", new [] {("MonoTests.System.IO", "xammac_net_4_5_Mono.Posix_test.dll", "MonoTests.System.IO.StdioFileStreamTest")}},
|
||||
{"MonoSecurityTests", new [] {("MonoTests.System.Security.Cryptography", "xammac_net_4_5_Mono.Security_test.dll", "MonoTests.System.Security.Cryptography.SHA224ManagedTest")}},
|
||||
{"SystemComponentModelDataAnnotationsTests", new [] {("MonoTests.System.ComponentModel.DataAnnotations", "xammac_net_4_5_System.ComponentModel.DataAnnotations_test.dll", "MonoTests.System.ComponentModel.DataAnnotations.AssociatedMetadataTypeTypeDescriptionProviderTests")} },
|
||||
{"SystemConfigurationTests", new [] {("MonoTests.System.Configuration", "xammac_net_4_5_System.Configuration_test.dll", "MonoTests.System.Configuration.ProviderCollectionTest")}},
|
||||
{"SystemCoreTests", new [] {("MonoTests.System.Threading", "xammac_net_4_5_System.Core_test.dll", "MonoTests.System.Threading.ReaderWriterLockSlimTests")}},
|
||||
{"SystemDataLinqTests", new [] {("DbLinqTest", "xammac_net_4_5_System.Data.Linq_test.dll", "DbLinqTest.MsSqlDataContextTest")}},
|
||||
{"SystemDataTests", new [] {("MonoTests.System.Xml", "xammac_net_4_5_System.Data_test.dll", "MonoTests.System.Xml.XmlDataDocumentTest2")}},
|
||||
{"SystemIOCompressionFileSystemTests", new [] {("MonoTests.System.IO.Compression.FileSystem", "xammac_net_4_5_System.IO.Compression.FileSystem_test.dll", "MonoTests.System.IO.Compression.FileSystem.ZipArchiveTests")}},
|
||||
{"SystemIOCompressionTests", new [] {("MonoTests.System.IO.Compression", "xammac_net_4_5_System.IO.Compression_test.dll", "MonoTests.System.IO.Compression.ZipArchiveTests")}},
|
||||
{"SystemIdentityModelTests", new [] {("MonoTests.System.IdentityModel.Tokens", "xammac_net_4_5_System.IdentityModel_test.dll", "MonoTests.System.IdentityModel.Tokens.InMemorySymmetricSecurityKeyTest")}},
|
||||
{"SystemJsonTests", new [] {("MonoTests.System", "xammac_net_4_5_System.Json_test.dll", "MonoTests.System.JsonValueTests")}},
|
||||
{"SystemNetHttpTests", new [] {("MonoTests.System.Net.Http", "xammac_net_4_5_System.Net.Http_test.dll", "MonoTests.System.Net.Http.ByteArrayContentTest")}},
|
||||
{"SystemNumericsTests", new [] {("MonoTests.System.Numerics", "xammac_net_4_5_System.Numerics_test.dll", "MonoTests.System.Numerics.BigIntegerTest")}},
|
||||
{"SystemRuntimeSerializationFormattersSoapTests", new [] {("MonoTests.System.Runtime.Serialization.Formatters.Soap", "xammac_net_4_5_System.Runtime.Serialization.Formatters.Soap_test.dll", "MonoTests.System.Runtime.Serialization.Formatters.Soap.SerializationCallbackTest")}},
|
||||
{"SystemSecurityTests", new [] {("MonoCasTests.System.Security.Cryptography", "xammac_net_4_5_System.Security_test.dll", "MonoCasTests.System.Security.Cryptography.CryptographicAttributeObjectCas")}},
|
||||
{"SystemTransactionsTests", new [] {("MonoTests.System.Transactions", "xammac_net_4_5_System.Transactions_test.dll", "MonoTests.System.Transactions.AsyncTest")}},
|
||||
{"SystemXmlLinqTests", new [] {("MonoTests.System.Xml", "xammac_net_4_5_System.Xml.Linq_test.dll", "MonoTests.System.Xml.ExtensionsTest")}},
|
||||
{"SystemXmlTests", new [] {("nist_dom.fundamental", "xammac_net_4_5_System.Xml_test.dll", "nist_dom.fundamental.AttrTest")}},
|
||||
{"SystemTests", new [] {("MonoCasTests.System", "xammac_net_4_5_System_test.dll", "MonoCasTests.System.FileStyleUriParserCas")}},
|
||||
{"MicrosoftCSharpXunit", new [] {("Microsoft.CSharp.RuntimeBinder.Tests", "xammac_net_4_5_Microsoft.CSharp_xunit-test.dll", "Microsoft.CSharp.RuntimeBinder.Tests.AccessTests")}},
|
||||
{"SystemCoreXunit", new [] {("System.Dynamic.Tests", "xammac_net_4_5_System.Core_xunit-test.dll", "System.Dynamic.Tests.BinaryOperationTests")}},
|
||||
{"SystemDataXunit", new [] {("System.Data.SqlClient.Tests", "xammac_net_4_5_System.Data_xunit-test.dll", "System.Data.SqlClient.Tests.CloneTests")}},
|
||||
{"SystemJsonXunit", new [] {("System.Json.Tests", "xammac_net_4_5_System.Json_xunit-test.dll", "System.Json.Tests.JsonArrayTests")}},
|
||||
{"SystemNumericsXunit", new [] {("System.Numerics.Tests", "xammac_net_4_5_System.Numerics_xunit-test.dll", "System.Numerics.Tests.GenericVectorTests")}},
|
||||
{"SystemRuntimeCompilerServicesUnsafeXunit", new [] {("System.Runtime.CompilerServices", "xammac_net_4_5_System.Runtime.CompilerServices.Unsafe_xunit-test.dll", "System.Runtime.CompilerServices.UnsafeTests")}},
|
||||
{"SystemXmlLinqXunit", new [] {("Microsoft.Test.ModuleCore", "xammac_net_4_5_System.Xml.Linq_xunit-test.dll", "Microsoft.Test.ModuleCore.LtmContext")}},
|
||||
{"SystemServiceModelTests", new [] {("MonoTests.System.ServiceModel", "xammac_net_4_5_System.ServiceModel_test.dll", "MonoTests.System.ServiceModel.Bug36080")}},
|
||||
{"SystemSecurityXunit", new [] {("System.Security.Cryptography.Pkcs.Tests", "xammac_net_4_5_System.Security_xunit-test.dll", "System.Security.Cryptography.Pkcs.Tests.CryptographicAttributeObjectCollectionTests")}},
|
||||
{"SystemXunit", new [] {("RegexTestNamespace", "xammac_net_4_5_System_xunit-test.dll", "RegexTestNamespace.RegexTestClass")}},
|
||||
{"CorlibXunit", new [] {("System.Collections.Generic.Tests", "xammac_net_4_5_corlib_xunit-test.dll", "System.Collections.Generic.Tests.ByteComparersTests")}},
|
||||
};
|
||||
|
||||
public static async Task<string> GenerateCodeAsync (string projectName, bool isXunit, string templatePath, Platform platform)
|
||||
{
|
||||
Dictionary<string, (string testNamespace, string testAssembly, string testType)[]> cache = null;
|
||||
switch (platform){
|
||||
case Platform.iOS:
|
||||
case Platform.TvOS:
|
||||
case Platform.WatchOS:
|
||||
throw new InvalidOperationException ("All iOS projects should be using the sdk test assemblies and not compile them.");
|
||||
case Platform.MacOSFull:
|
||||
case Platform.MacOSModern:
|
||||
cache = MacCache;
|
||||
break;
|
||||
}
|
||||
var importStringBuilder = new StringBuilder ();
|
||||
var keyValuesStringBuilder = new StringBuilder ();
|
||||
foreach (var typeInfo in cache [projectName]) {
|
||||
importStringBuilder.AppendLine ($"using {typeInfo.testNamespace};");
|
||||
keyValuesStringBuilder.AppendLine ($"\t\t\t{{ \"{typeInfo.testAssembly}\", typeof ({typeInfo.testType})}}, ");
|
||||
}
|
||||
// got the lines we want to add, read the template and substitute
|
||||
using (var reader = new StreamReader(templatePath)) {
|
||||
var result = await reader.ReadToEndAsync ();
|
||||
result = result.Replace (UsingReplacement, importStringBuilder.ToString ());
|
||||
result = result.Replace (KeysReplacement, keyValuesStringBuilder.ToString ());
|
||||
result = result.Replace (IsxUnitReplacement, (isXunit)? "true" : "false");
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
public static async Task<string> GenerateCodeAsync ((string FailureMessage, Dictionary<string, Type> Types) typeRegistration, bool isXunit,
|
||||
string templatePath)
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче