예제 #1
0
        public void TestExtremes()
        {
            CoOrdinate first = new CoOrdinate(0, 0);
            CoOrdinate last  = new CoOrdinate(4, 4);

            Assert.IsTrue(first.Equals(CoOrdinate.FromIndex(0)));
            Assert.IsTrue(last.Equals(CoOrdinate.FromIndex(24)));
        }
예제 #2
0
        public void TestCoordinate()
        {
            CoOrdinate co = new CoOrdinate(2, 2);

            Assert.AreEqual(12, co.Index);
            CoOrdinate co2 = new CoOrdinate(2, 2);

            Assert.IsTrue(co.Equals(co2));
            Assert.IsTrue(co.Equals(CoOrdinate.FromIndex(12)));
        }