System.Reflection.TargetInvocationException: Exception has been thrown
by the target of an invocation. ---> System.NotSupportedException: The
'get' method is not supported on this property.
at System.Security.Permissions.EnvironmentPermissionAttribute.get_All
()
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object
[] arguments, ref SignatureStruct sig, MethodAttributes
methodAttributes, RuntimeTypeHandle typeOwner)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags
invokeAttr, Binder binder, Object[] parameters, CultureInfo culture,
Boolean skipVisibilityChecks)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags
invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.Reflection.RuntimePropertyInfo.GetValue(Object obj, Object[]
index)
at
Castle.DynamicProxy.Generators.Emitters.CustomAttributeUtil.GetPropertyValues
(Type attType, PropertyInfo[]& properties, Attribute attribute)
at
Castle.DynamicProxy.Generators.Emitters.CustomAttributeUtil.CreateCustomAttribute
(Attribute attribute)
at
Castle.DynamicProxy.Generators.Emitters.AbstractTypeEmitter.DefineCustomAttribute
(Attribute attribute)
at
Castle.DynamicProxy.Generators.BaseProxyGenerator.ReplicateNonInheritableAttributes
(Type targetType, ClassEmitter emitter)
at Castle.DynamicProxy.Generators.ClassProxyGenerator.GenerateCode(Type
[] interfaces, ProxyGenerationOptions options)
at Castle.DynamicProxy.DefaultProxyBuilder.CreateClassProxy(Type
classToProxy, Type[] additionalInterfacesToProxy,
ProxyGenerationOptions options)
at Castle.DynamicProxy.ProxyGenerator.CreateClassProxyType(Type
classToProxy, Type[] additionalInterfacesToProxy,
ProxyGenerationOptions options)
at Castle.DynamicProxy.ProxyGenerator.CreateClassProxy(Type
classToProxy, Type[] additionalInterfacesToProxy,
ProxyGenerationOptions options, Object[] constructorArguments,
IInterceptor[] interceptors)
at Castle.DynamicProxy.ProxyGenerator.CreateClassProxy(Type
classToProxy, Type[] additionalInterfacesToProxy,
ProxyGenerationOptions options, IInterceptor[] interceptors)
at Castle.DynamicProxy.ProxyGenerator.CreateClassProxy(Type
classToProxy, Type[] additionalInterfacesToProxy, IInterceptor[]
interceptors)
at Moq.Mock`1.<InitializeInstance>b__0()
at Moq.PexProtector.Invoke(Action action)
at Moq.Mock`1.InitializeInstance()
at Moq.Mock`1.get_Object()
--
Post: moq...@googlegroups.com
Unsubscribe: moqdisc-u...@googlegroups.com