Ejemplo n.º 1
0
        public void Equals_WhenArgumentIsObjectAndDiffers_ReturnsFalse()
        {
            var    cellLocation1 = new CellLocation(3, 4);
            object cellLocation2 = new CellLocation(5, 3);

            bool result = cellLocation1.Equals(cellLocation2);

            Assert.IsFalse(result);
        }
Ejemplo n.º 2
0
        public void Equals_WhenDiffersByXandY_ReturnsFalse()
        {
            var cellLocation1 = new CellLocation(4, 5);
            var cellLocation2 = new CellLocation(5, 4);

            bool result = cellLocation1.Equals(cellLocation2);

            Assert.IsFalse(result);
        }
Ejemplo n.º 3
0
        public void Equals_WhenArgumentIsObjectAndNotDiffers_ReturnsTrue()
        {
            var    cellLocation1 = new CellLocation(2, 2);
            object cellLocation2 = new CellLocation(2, 2);

            bool result = cellLocation1.Equals(cellLocation2);

            Assert.IsTrue(result);
        }
Ejemplo n.º 4
0
        public void Equals_WhenTheSame_ReturnsTrue()
        {
            var cellLocation1 = new CellLocation(5, 1);
            var cellLocation2 = new CellLocation(5, 1);

            bool result = cellLocation1.Equals(cellLocation2);

            Assert.IsTrue(result);
        }