Esempio n. 1
0
 public void TestQuadCanComputePerimeter()
 {
     Quadrilateral myquad = new Quadrilateral();
     myquad.Top = 2;
     myquad.Right = 2;
     myquad.Left = 2;
     myquad.Bottom = 2;
     Assert.AreEqual(8, myquad.Perimeter());
 }
 public void TestQuadrilateralCanComputePerimeter()
 {
     Quadrilateral myQuadrilateral = new Quadrilateral();
     myQuadrilateral.Top = 2;
     myQuadrilateral.Right = 4;
     myQuadrilateral.Bottom = 99;
     myQuadrilateral.Left = 6;
     Assert.AreEqual(myQuadrilateral.Perimeter(), 111);
 }
 public void TestQuadPerimetersAreTheSame()
 {
     Quadrilateral myquad1 = new Quadrilateral();
     myquad1.Top = 2;
     myquad1.Right = 2;
     myquad1.Left = 2;
     myquad1.Bottom = 2;
     Quadrilateral myquad2 = new Quadrilateral(2, 2, 2, 2);
     Assert.AreEqual(myquad1.Perimeter(), myquad2.Perimeter());
 }
Esempio n. 4
0
 public void TestQuadHasDefaultSize()
 {
     Quadrilateral myquad = new Quadrilateral();
     myquad.Perimeter();
 }
Esempio n. 5
0
 public void TestQuadCanComputePerimeter2()
 {
     Quadrilateral myquad = new Quadrilateral(2, 2, 2, 2);
     Assert.AreEqual(8, myquad.Perimeter());
 }