예제 #1
0
        public void Factory_ShouldCreateANewInstance([ValueSource(nameof(Paramz))] ITuple paramz)
        {
            List <string> instance = (List <string>)ProxyActivator.Create(typeof(List <string>)).Invoke(paramz);

            Assert.IsNotNull(instance);
        }
예제 #2
0
 public void Factory_ShouldThrowOnInvalidParam([ValueSource(nameof(BadParamz))] ITuple paramz) =>
 Assert.Throws <MissingMemberException>(() => ProxyActivator.Create(typeof(List <string>)).Invoke(paramz));
예제 #3
0
 public void Create_ShouldBuildAFactory() =>
 Assert.DoesNotThrow(() => ProxyActivator.Create(typeof(List <string>)));