public void WithObjectNone_ReturnsTrue() { var source = new None(); var other = new None(); var result = source.Equals((object)other); Assert.True(result); }
public void WithIMaybeNull_ThrowsArgumentNullException() { var source = new None(); IMaybe other = null; // ReSharper disable once ExpressionIsAlwaysNull Assert.Throws <ArgumentNullException>(() => source.Equals(other)); }
public void WithIMaybeSome_ReturnsFalse() { var source = new None(); var other = Maybe <int> .Some(1); var result = source.Equals((IMaybe)other); Assert.False(result); }
public void WithIMaybeNone_ReturnsTrue() { var source = new None(); var other = Maybe <int> .None(); var result = source.Equals((IMaybe)other); Assert.True(result); }
public void WithObjectMaybeSome_ReturnsFalse() { var source = new None(); var other = (object)Maybe <int> .Some(1); var result = source.Equals(other); Assert.False(result); }
public void WithObjectMaybeNone_ReturnsTrue() { var source = new None(); var other = (object)Maybe <int> .None(); var result = source.Equals(other); Assert.True(result); }
public void WithObjectNull_ReturnsFalse() { var source = new None(); object other = null; // ReSharper disable once ExpressionIsAlwaysNull var result = source.Equals(other); Assert.False(result); }