public void ShouldThrow_WhenCurrentIsNull() { Action act = () => TypeExtensions.IsSubclassOfOpenGeneric(null, typeof(AppleException)); act.Should().Throw <ArgumentNullException>().Which.ParamName.Should().Be("current"); }
public void ShouldThrow_WhenBaseTypeIsNull() { Action act = () => TypeExtensions.IsSubclassOfOpenGeneric(typeof(AppleException), null); act.Should().Throw <ArgumentNullException>().Which.ParamName.Should().Be("baseType"); }
public void ShouldDetermineSubtype(Type c, Type b, bool expected) { TypeExtensions.IsSubclassOfOpenGeneric(c, b).Should().Be(expected); }