コード例 #1
0
        public void TestTask1_1()
        {
            Point   x         = new Point(1, 3);
            Point   y         = new Point(5, 1);
            Task1_1 rectangle = new Task1_1(x, y);

            Assert.AreEqual(rectangle.Square(), 8);
            Assert.AreEqual(rectangle.Perimeter(), 12);
        }
コード例 #2
0
        public void ResultTaskTest1()
        {
            double X        = 2;
            double expected = 0;

            Task1_1 one    = new Task1_1(X);
            double  actual = one.ResultTask();

            Assert.AreEqual(expected, actual);
        }