Пример #1
0
        public void TestDelete()
        {
            //Arrange
            MeassurementController controller = new MeassurementController();

            //Act
            controller.Delete(2);
            Meassurement returnedMeassurement = controller.GetMeassurementById(2);


            //Assert
            Assert.AreEqual(0, returnedMeassurement.Id);
        }
Пример #2
0
        public void TestGetById()
        {
            //Arrange
            MeassurementController controller = new MeassurementController();
            //Act
            Meassurement returnedMeassurement = controller.GetMeassurementById(1);

            //Assert

            if (returnedMeassurement != null)
            {
                Assert.AreEqual(1, returnedMeassurement.Id);
            }
            else
            {
                Assert.IsTrue(true);
            }
        }