public static void GetTypeByName()
{
RemoteInvokeOptions options = new RemoteInvokeOptions();
RemoteInvoke(() =>
{
string test1 = testtype;
Type t1 = Type.GetType(test1,
(aName) => aName.Name == "Foo" ?
Assembly.LoadFrom(destTestAssemblyPath) : null,
typeloader,
true
);
Assert.NotNull(t1);
string test2 = "System.Collections.Generic.Dictionary`2[[Program, TestLoadAssembly], [Program, TestLoadAssembly]]";
Type t2 = Type.GetType(test2, assemblyloader, typeloader, true);
Assert.NotNull(t2);
Assert.Equal(t1, t2);
return SuccessExitCode;
}, options).Dispose();
}