Remove feature exclude xml tests (#89111)
authorMike Voorhees <mrvoorhe@users.noreply.github.com>
Fri, 21 Jul 2023 12:22:03 +0000 (08:22 -0400)
committerGitHub <noreply@github.com>
Fri, 21 Jul 2023 12:22:03 +0000 (14:22 +0200)
illink dropped the exclude feature functionality, so will we.

I believe Unity was the last user of these tests so it's safe to delete them now.

14 files changed:
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib1.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib2.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.xml [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.xml [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.xml [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.xml [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.xml [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.cs [deleted file]
src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.xml [deleted file]

diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib1.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib1.cs
deleted file mode 100644 (file)
index ee45779..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.Dependencies
-{
-       public class OnAssembly_Lib1
-       {
-               public static void UsedSoCompilerDoesntRemoveReference ()
-               {
-               }
-
-               public class FeatureOneClass
-               {
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib2.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/Dependencies/OnAssembly_Lib2.cs
deleted file mode 100644 (file)
index 032ad67..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.Dependencies
-{
-       public class OnAssembly_Lib2
-       {
-               public static void UsedSoCompilerDoesntRemoveReference ()
-               {
-               }
-
-               public class FeatureTwoClass
-               {
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.cs
deleted file mode 100644 (file)
index 6f53fcf..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-using Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.Dependencies;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupCompileBefore ("library1.dll", new[] { typeof (OnAssembly_Lib1) })]
-       [SetupCompileBefore ("library2.dll", new[] { typeof (OnAssembly_Lib2) })]
-       [RemovedTypeInAssembly ("library1.dll", typeof (OnAssembly_Lib1.FeatureOneClass))]
-       [KeptTypeInAssembly ("library2.dll", typeof (OnAssembly_Lib2.FeatureTwoClass))]
-       [SetupLinkerDescriptorFile ("OnAssembly.xml")]
-       public class OnAssembly
-       {
-               public static void Main ()
-               {
-                       OnAssembly_Lib1.UsedSoCompilerDoesntRemoveReference ();
-                       OnAssembly_Lib2.UsedSoCompilerDoesntRemoveReference ();
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnAssembly.xml
deleted file mode 100644 (file)
index f512ad9..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<linker>
-    <assembly fullname="library1, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null" feature="one">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.Dependencies.OnAssembly_Lib1/FeatureOneClass"/>
-    </assembly>
-    <assembly fullname="library2, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null" feature="two">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.Dependencies.OnAssembly_Lib2/FeatureTwoClass"/>
-    </assembly>
-</linker>
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.cs
deleted file mode 100644 (file)
index 47ae4e6..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-using System;
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupLinkerDescriptorFile ("OnEvent.xml")]
-       public class OnEvent
-       {
-               public static void Main ()
-               {
-               }
-
-               public event EventHandler<EventArgs> FeatureOne;
-
-               [Kept]
-               public event EventHandler<EventArgs> FeatureTwo { [Kept] add { } [Kept] remove { } }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnEvent.xml
deleted file mode 100644 (file)
index c6a851c..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<linker>
-    <assembly fullname="test, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnEvent">
-            <event signature="System.EventHandler`1&lt;System.EventArgs&gt; FeatureOne" feature="one"/>
-        </type>
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnEvent">
-            <event signature="System.EventHandler`1&lt;System.EventArgs&gt; FeatureTwo" feature="two"/>
-        </type>
-    </assembly>
-</linker>
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.cs
deleted file mode 100644 (file)
index 0fcea8b..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupLinkerDescriptorFile ("OnField.xml")]
-       public class OnField
-       {
-               public static void Main ()
-               {
-               }
-
-               private int _featureOne;
-
-               [Kept]
-               private int _featureTwo;
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnField.xml
deleted file mode 100644 (file)
index a1afd0b..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<linker>
-    <assembly fullname="test, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnField">
-            <field signature="System.Int32 _featureOne" feature="one"/>
-        </type>
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnField">
-            <field signature="System.Int32 _featureTwo" feature="two"/>
-        </type>
-    </assembly>
-</linker>
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.cs
deleted file mode 100644 (file)
index 503a5a4..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupLinkerDescriptorFile ("OnMethod.xml")]
-       public class OnMethod
-       {
-               public static void Main ()
-               {
-               }
-
-               public void FeatureOne ()
-               {
-               }
-
-               [Kept]
-               public void FeatureTwo ()
-               {
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnMethod.xml
deleted file mode 100644 (file)
index 53fb365..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<linker>
-    <assembly fullname="test, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnMethod">
-            <method signature="System.Void FeatureOne()" feature="one"/>
-        </type>
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnMethod">
-            <method signature="System.Void FeatureTwo()" feature="two"/>
-        </type>
-    </assembly>
-</linker>
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.cs
deleted file mode 100644 (file)
index eae178b..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupLinkerDescriptorFile ("OnProperty.xml")]
-       public class OnProperty
-       {
-               public static void Main ()
-               {
-                       new Foo (); // Used to avoid lazy body marking
-               }
-
-               [Kept]
-               [KeptMember (".ctor()")]
-               class Foo
-               {
-                       public int FeatureOne { get; set; }
-
-                       [Kept]
-                       [KeptBackingField]
-                       public int FeatureTwo { [Kept] get; [Kept] set; }
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnProperty.xml
deleted file mode 100644 (file)
index fc0c458..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-<linker>
-    <assembly fullname="test, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnProperty/Foo">
-            <property signature="System.Int32 FeatureOne" accessors="all" feature="one"/>
-        </type>
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnProperty/Foo">
-            <property signature="System.Int32 FeatureTwo" accessors="all" feature="two"/>
-        </type>
-    </assembly>
-</linker>
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.cs b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.cs
deleted file mode 100644 (file)
index d21e10c..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-using Mono.Linker.Tests.Cases.Expectations.Assertions;
-using Mono.Linker.Tests.Cases.Expectations.Metadata;
-
-namespace Mono.Linker.Tests.Cases.LinkXml.FeatureExclude
-{
-       [TestCaseRequirements (TestRunCharacteristics.TargetingNetFramework, "--exclude-feature is not supported on .NET Core")]
-       [SetupLinkerArgument ("--exclude-feature", "one")]
-       [SetupLinkerDescriptorFile ("OnType.xml")]
-       public class OnType
-       {
-               public static void Main ()
-               {
-               }
-
-               class FeatureOneClass
-               {
-               }
-
-               [Kept]
-               [KeptMember (".ctor()")]
-               class FeatureTwoClass
-               {
-               }
-       }
-}
diff --git a/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.xml b/src/tools/illink/test/Mono.Linker.Tests.Cases/LinkXml/FeatureExclude/OnType.xml
deleted file mode 100644 (file)
index 9f21a61..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-<linker>
-    <assembly fullname="test, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null">
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnType/FeatureOneClass" feature="one"/>
-        <type fullname="Mono.Linker.Tests.Cases.LinkXml.FeatureExclude.OnType/FeatureTwoClass" feature="two"/>
-    </assembly>
-</linker>