public void CircleF_EqualsObject() { var circle1 = new CircleF(123.45f, 456.78f, 100.10f); var circle2 = new CircleF(123.45f, 456.78f, 100.10f); TheResultingValue(circle1.Equals((Object)circle2)).ShouldBe(true); TheResultingValue(circle1.Equals("This is a test")).ShouldBe(false); }
public void CircleF_EqualsCircleF() { var circle1 = new CircleF(123.45f, 456.78f, 100.10f); var circle2 = new CircleF(123.45f, 456.78f, 100.10f); var circle3 = new CircleF(123.45f, 555.55f, 100.10f); var circle4 = new CircleF(222.22f, 456.78f, 100.10f); TheResultingValue(circle1.Equals(circle2)).ShouldBe(true); TheResultingValue(circle1.Equals(circle3)).ShouldBe(false); TheResultingValue(circle1.Equals(circle4)).ShouldBe(false); }