예제 #1
0
 public void GetTypeByNameTest( )
 {
     using (var module = new NativeModule(TestModuleName))
     {
         // while GetTypeByName is exposed on the module it isn't really specific to the module
         // That is, the type belongs to the context and GetTypeByName() is just a convenience
         // wrapper to access types for a module.
         var type = module.GetTypeByName(StructTestName);
         Assert.IsNull(type);
         var expectedType = module.Context.CreateStructType(StructTestName);
         var actualType   = module.GetTypeByName(StructTestName);
         Assert.AreSame(expectedType, actualType);
     }
 }