Beispiel #1
0
 public void TestForTriangle()
 {
     objectForAll = new Triangle(5, 2);
     result       = objectForAll.CalculateAreaOfShape();
     Assert.AreEqual(5, result, 1);
 }
Beispiel #2
0
 public void TestForRectangle()
 {
     objectForAll = new Rectangle(5, 5, 5);
     result       = objectForAll.CalculateAreaOfShape();
     Assert.AreEqual(125, result, 1);
 }
Beispiel #3
0
 public void TestForSquare()
 {
     objectForAll = new Square(5);
     result       = objectForAll.CalculateAreaOfShape();
     Assert.AreEqual(25, result, 1);
 }
Beispiel #4
0
 public void TestForCircle()
 {
     objectForAll = new Circle(5);
     result       = objectForAll.CalculateAreaOfShape();
     Assert.AreEqual(78.5, result, 1);
 }