public void ByTest11() { var value = new Test11(); var values = new Test11[] { value }; var expect = (Test11[])value.To(typeof(Test11[])); Assert.True(values.SequenceEqual(expect)); }
public void ByTest11() { var value = new Test11(); var values = new Test11[] { value }; var expect = value.To <Test11[]>(); Assert.True(values.SequenceEqual(expect)); }
public void ByDerived() { var value = new Test12() { Property11 = 2, Property12 = 4 }; var result = value.To <Test11>(); var expect = new Test11() { Property11 = 2 }; Assert.True(expect.Equals(result)); }