[d16-5] [Test] Bump mono and use the new splited tests. (#7648)
Bump mono to get the new splited test dlls and add them to be ran in xharness. Special logic is used for mscorlib so we make sure that all the 'parts' of the test dll do have the same configurations. Co-authored-by: Manuel de la Pena <mandel@microsoft.com> Co-authored-by: Waleed Chaudhry <54864665+wachaudh@users.noreply.github.com>
This commit is contained in:
Родитель
4eaf8c0ff1
Коммит
49d853a23d
|
@ -26,8 +26,6 @@ tests/bcl-test/BCLTests/generated
|
|||
tests/bcl-test/generated
|
||||
tests/bcl-test/BCL\ tests\ group*.csproj
|
||||
tests/bcl-test/Mac\ OS\ X\ BCL\ \tests*.csproj
|
||||
tests/bcl-test/mscorlib-mac-full.csproj
|
||||
tests/bcl-test/mscorlib-mac-modern.csproj
|
||||
tests/bcl-test/mscorlib.csproj
|
||||
tests/bcl-test/SystemCoreXunit.csproj
|
||||
tests/bcl-test/mscorlib*.csproj
|
||||
tests/bcl-test/SystemCoreXunit*.csproj
|
||||
tests/bcl-test/SystemXunit.csproj
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
NEEDED_MONO_VERSION := 8f396bbb408b5758fccb8602030b9fa5293ce718
|
||||
NEEDED_MONO_VERSION := bfcac9bd309a05bcc1820e9ff1cb167708e4d6f4
|
||||
NEEDED_MONO_BRANCH := 2019-10
|
||||
|
||||
MONO_DIRECTORY := mono
|
||||
|
|
|
@ -2605,7 +2605,8 @@ public class TestApp {
|
|||
[TestCase (Target.Dev, Profile.iOS, "link all", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "link sdk", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "monotouch-test", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "mscorlib", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "mscorlib Part 1", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "mscorlib Part 2", "Release64")]
|
||||
[TestCase (Target.Dev, Profile.iOS, "BCL tests group 1", "Release64")]
|
||||
public void BuildTestProject (Target target, Profile profile, string testname, string configuration)
|
||||
{
|
||||
|
|
|
@ -37,12 +37,12 @@ namespace xharness.BCLTestImporter {
|
|||
// generate all projects, then create a new iOSTarget per project
|
||||
foreach (var tp in projectGenerator.GenerateAlliOSTestProjects ()) {
|
||||
var prefix = tp.XUnit ? "xUnit" : "NUnit";
|
||||
var finalName = (tp.Name == "mscorlib") ? tp.Name : $"[{prefix}] Mono {tp.Name}"; // mscorlib is our special test
|
||||
var finalName = tp.Name.StartsWith ("mscorlib", StringComparison.Ordinal) ? tp.Name : $"[{prefix}] Mono {tp.Name}"; // mscorlib is our special test
|
||||
result.Add (new iOSTestProject (tp.Path) {
|
||||
Name = finalName,
|
||||
SkipiOSVariation = !tp.Platforms.Contains (Platform.iOS),
|
||||
SkiptvOSVariation = !tp.Platforms.Contains (Platform.TvOS),
|
||||
SkipwatchOS32Variation = tp.Name == "mscorlib", // mscorlib is our special test
|
||||
SkipwatchOS32Variation = tp.Name.StartsWith ("mscorlib", StringComparison.Ordinal), // mscorlib is our special test
|
||||
SkipwatchOSVariation = !tp.Platforms.Contains (Platform.WatchOS),
|
||||
FailureMessage = tp.Failure,
|
||||
RestoreNugetsInProject = true,
|
||||
|
@ -63,7 +63,7 @@ namespace xharness.BCLTestImporter {
|
|||
var result = new List<MacTestProject> ();
|
||||
foreach (var tp in projectGenerator.GenerateAllMacTestProjects (platform)) {
|
||||
var prefix = tp.XUnit ? "xUnit" : "NUnit";
|
||||
var finalName = (tp.Name == "mscorlib") ? tp.Name : $"[{prefix}] Mono {tp.Name}"; // mscorlib is our special test
|
||||
var finalName = tp.Name.StartsWith ("mscorlib", StringComparison.Ordinal) ? tp.Name : $"[{prefix}] Mono {tp.Name}"; // mscorlib is our special test
|
||||
result.Add (new MacTestProject (tp.Path, targetFrameworkFlavor: flavor) {
|
||||
Name = finalName,
|
||||
Platform = "AnyCPU",
|
||||
|
@ -86,4 +86,3 @@ namespace xharness.BCLTestImporter {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -122,7 +122,7 @@ namespace xharness
|
|||
|
||||
public virtual void Convert ()
|
||||
{
|
||||
var testName = TestName == "mscorlib" ? "corlib" : TestName;
|
||||
var testName = TestName.StartsWith ("mscorlib", StringComparison.Ordinal) ? "corlib" : TestName;
|
||||
var main_test_sources = Path.Combine (MonoPath, "mcs", "class", testName, testName + "_test.dll.sources");
|
||||
if (!File.Exists (main_test_sources)) // TODO: revert this
|
||||
return;
|
||||
|
@ -202,7 +202,7 @@ namespace xharness
|
|||
|
||||
string GetFileList ()
|
||||
{
|
||||
var testName = TestName == "mscorlib" ? "corlib" : TestName;
|
||||
var testName = TestName.StartsWith("mscorlib", StringComparison.Ordinal) ? "corlib" : TestName;
|
||||
var main_test_sources = Path.Combine (MonoPath, "mcs", "class", testName, testName + "_test.dll.sources");
|
||||
if (!File.Exists (main_test_sources)) // TODO: revert this
|
||||
return "";
|
||||
|
|
|
@ -303,7 +303,7 @@ namespace xharness
|
|||
yield return new TestData { Variation = "Release (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = false, Profiling = false, Undefines = "FULL_AOT_RUNTIME" };
|
||||
}
|
||||
break;
|
||||
case "mscorlib":
|
||||
case string name when name.StartsWith ("mscorlib", StringComparison.Ordinal):
|
||||
if (supports_debug)
|
||||
yield return new TestData { Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true};
|
||||
if (supports_interpreter) {
|
||||
|
|
|
@ -453,7 +453,7 @@ namespace xharness
|
|||
}
|
||||
var chunks = new List<string> ();
|
||||
if (target is WatchOSTarget && target.IsBCLProject) {
|
||||
if (target.Name == "mscorlib") {
|
||||
if (target.Name.StartsWith ("mscorlib", StringComparison.Ordinal)) {
|
||||
for (int i = (int) 'A'; i <= (int) 'Z'; i++) {
|
||||
chunks.Add (((char) i).ToString () + ((char) i).ToString ());
|
||||
}
|
||||
|
|
|
@ -70,8 +70,8 @@ namespace xharness
|
|||
protected override void CalculateName ()
|
||||
{
|
||||
if (TargetDirectory.Contains ("bcl-test")) {
|
||||
if (TestProject.Name == "mscorlib")
|
||||
Name = "mscorlib";
|
||||
if (TestProject.Name.StartsWith ("mscorlib", StringComparison.Ordinal))
|
||||
Name = TestProject.Name;
|
||||
else {
|
||||
var bclIndex = TestProject.Name.IndexOf ("BCL", StringComparison.Ordinal);
|
||||
// most of the BCL test are grouped, but there are a number that are not, in those cases remove the "{testype} Mono " prefix
|
||||
|
|
|
@ -135,10 +135,11 @@ namespace BCLTestImporter {
|
|||
new BclTestProjectInfo { Name = "SystemNetHttpFunctionalTestsXunit", assemblies = new [] { "monotouch_System.Net.Http.FunctionalTests_xunit-test.dll" }, Group = "BCL tests group 5" },
|
||||
|
||||
// Special assemblies that are in a single application due to their size being to large for the iOS 32b.
|
||||
new BclTestProjectInfo { Name = "mscorlib", assemblies = new [] { "monotouch_corlib_xunit-test.dll" }, Group = "mscorlib" }, // special testcase for the corlib which is later used in xHarness for diff config options
|
||||
new BclTestProjectInfo { Name = "SystemCoreXunit", assemblies = new [] { "monotouch_System.Core_xunit-test.dll" }, Group = "SystemCoreXunit" }, // special test case, this dll is to large for the iOS 32b
|
||||
new BclTestProjectInfo { Name = "mscorlib Part 1", assemblies = new [] { "monotouch_corlib_xunit-test.part1.dll" }, Group = "mscorlib Part 1" }, // special testcase for the corlib which is later used in xHarness for diff config options
|
||||
new BclTestProjectInfo { Name = "mscorlib Part 2", assemblies = new [] { "monotouch_corlib_xunit-test.part2.dll" }, Group = "mscorlib Part 2" },
|
||||
new BclTestProjectInfo { Name = "SystemCoreXunit Part 1", assemblies = new [] { "monotouch_System.Core_xunit-test.part1.dll" }, Group = "SystemCoreXunit Part 1" },
|
||||
new BclTestProjectInfo { Name = "SystemCoreXunit Part 2", assemblies = new [] { "monotouch_System.Core_xunit-test.part2.dll" }, Group = "SystemCoreXunit Part 2" },
|
||||
new BclTestProjectInfo { Name = "SystemXunit", assemblies = new [] { "monotouch_System_xunit-test.dll" }, ExtraArgs = $"--xml={Path.Combine (Harness.RootDirectory, "bcl-test", "SystemXunitLinker.xml")} --optimize=-custom-attributes-removal", Group = "SystemXunit" }, // special case due to the need of the extra args
|
||||
|
||||
};
|
||||
|
||||
static readonly List <string> CommonIgnoredAssemblies = new List <string> {
|
||||
|
|
Загрузка…
Ссылка в новой задаче