Esempio n. 1
0
        public void NineFor3x3Squre()
        {
            var squre = new Squre {
                Height = 3
            };

            Assert.AreEqual(9, AreaCalculator.CalculateArea(squre));
        }
Esempio n. 2
0
        public void SixFor2x3Rectange()
        {
            var myRectangle = new Rectangle {
                Height = 2, Width = 3
            };

            Assert.AreEqual(6, AreaCalculator.CalculateArea(myRectangle));
        }
Esempio n. 3
0
        public void TwentyFor4x5Squre()
        {
            //Failed means not substitutable
            var rectangle = new Squre();

            rectangle.Height = 4;
            rectangle.Width  = 5;
            Assert.AreEqual(20, AreaCalculator.CalculateArea(rectangle));
        }