diff options
Diffstat (limited to 'test/Mono.Linker.Tests.Cases/Reflection/AssemblyImportedViaReflectionWithReference.cs')
-rw-r--r-- | test/Mono.Linker.Tests.Cases/Reflection/AssemblyImportedViaReflectionWithReference.cs | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/test/Mono.Linker.Tests.Cases/Reflection/AssemblyImportedViaReflectionWithReference.cs b/test/Mono.Linker.Tests.Cases/Reflection/AssemblyImportedViaReflectionWithReference.cs new file mode 100644 index 000000000..716207d22 --- /dev/null +++ b/test/Mono.Linker.Tests.Cases/Reflection/AssemblyImportedViaReflectionWithReference.cs @@ -0,0 +1,23 @@ +using System; +using Mono.Linker.Tests.Cases.Expectations.Assertions; +using Mono.Linker.Tests.Cases.Expectations.Metadata; + +namespace Mono.Linker.Tests.Cases.Reflection +{ + [IgnoreTestCase ("Requires support for using a type in an unreferences assembly via reflection")] + [SetupCompileBefore ("reference.dll", new [] { "Dependencies/AssemblyDependency.cs" }, addAsReference: false)] + [SetupCompileBefore ("library.dll", new [] { "Dependencies/AssemblyDependencyWithReference.cs" }, references: new []{"reference.dll"}, addAsReference: false)] + [KeptAssembly ("reference.dll")] + [KeptAssembly ("library.dll")] + [KeptTypeInAssembly ("library.dll", "Mono.Linker.Tests.Cases.Reflection.Dependencies.AssemblyDependencyWithReference")] + [KeptTypeInAssembly ("reference.dll", "Mono.Linker.Tests.Cases.Reflection.Dependencies.AssemblyDependency")] + public class AssemblyImportedViaReflectionWithReference + { + public static void Main () + { + const string newAssemblyType = "Mono.Linker.Tests.Cases.Reflection.Dependencies.AssemblyDependencyWithReference, library, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null"; + var res = Type.GetType (newAssemblyType, true); + return; + } + } +}
\ No newline at end of file |