public static void TestDebuggerAttributes_Null()
        {
            Type proxyType = DebuggerAttributes.GetProxyType(ImmutableSortedSet.CreateBuilder <int>());
            TargetInvocationException tie = Assert.Throws <TargetInvocationException>(() => Activator.CreateInstance(proxyType, (object)null));

            Assert.IsType <ArgumentNullException>(tie.InnerException);
        }
Exemplo n.º 2
0
        public static void TestDebuggerAttributes_Null()
        {
            Type proxyType = DebuggerAttributes.GetProxyType(ImmutableStack.Create <string>("1", "2", "3"));
            TargetInvocationException tie = Assert.Throws <TargetInvocationException>(() => Activator.CreateInstance(proxyType, (object)null));

            Assert.IsType <ArgumentNullException>(tie.InnerException);
        }
Exemplo n.º 3
0
        public static void TestDebuggerAttributes_Null()
        {
            Type proxyType = DebuggerAttributes.GetProxyType(new ConcurrentDictionary <string, int>());
            TargetInvocationException tie = Assert.Throws <TargetInvocationException>(() => Activator.CreateInstance(proxyType, (object)null));

            Assert.IsType <ArgumentNullException>(tie.InnerException);
        }
Exemplo n.º 4
0
        public void DebuggerTypeProxy_Ctor_NullArgument_Throws()
        {
            IProducerConsumerCollection <int> c = CreateProducerConsumerCollection();
            Type proxyType = DebuggerAttributes.GetProxyType(c);
            var  tie       = Assert.Throws <TargetInvocationException>(() => Activator.CreateInstance(proxyType, new object[] { null }));

            Assert.IsType <ArgumentNullException>(tie.InnerException);
        }
Exemplo n.º 5
0
        public static void TestDebuggerAttributes_Null(object obj)
        {
            Type proxyType = DebuggerAttributes.GetProxyType(obj);

            Assert.Throws <TargetInvocationException>(() => Activator.CreateInstance(proxyType, (object)null));
        }