public void Exception_is_thrown_for_method_that_cannot_be_bound_to_delegate_type()
        {
            var element = new ConfigLoadedHandlerElement(1)
            {
                TypeName = GetType().AssemblyQualifiedName, MethodName = "WagonWheel"
            };

            var exception = Assert.Throws <InvalidOperationException>(() => element.CreateHandlerDelegate());

            Assert.Equal(Strings.ConfigEventCannotBind("WagonWheel", GetType().AssemblyQualifiedName), exception.Message);
            Assert.NotNull(exception.InnerException);
        }
コード例 #2
0
 public void AddElement(ConfigLoadedHandlerElement element)
 {
     base.BaseAdd(element);
 }