Ejemplo n.º 1
0
 public void PropertyRegisteredTwice()
 {
     try
     {
         var root = new BadGetSetTwo();
         var tmp  = root.Id;
     }
     catch (TypeInitializationException ex)
     {
         if (ex.InnerException != null)
         {
             throw ex.InnerException;
         }
         else
         {
             throw;
         }
     }
 }
Ejemplo n.º 2
0
        public void PropertyRegisteredTwice()
        {
            IDataPortal <BadGetSetTwo> dataPortal = _testDIContext.CreateDataPortal <BadGetSetTwo>();

            try
            {
                var root = BadGetSetTwo.GetObject(dataPortal);
                var tmp  = root.Id;
            }
            catch (TypeInitializationException ex)
            {
                if (ex.InnerException != null)
                {
                    throw ex.InnerException;
                }
                else
                {
                    throw;
                }
            }
        }