Пример #1
0
        public void ErnieController_Put_Success()
        {
            //arrange
            int    id    = 5;
            string value = "Rubber Ducky";

            //act
            IActionResult result   = _controller.Put(id, value);
            OkResult      response = (OkResult)result;

            //assert
            Assert.IsInstanceOfType(result, typeof(IActionResult), "'result' type must be of IActionResult");
            Assert.AreEqual(StatusCodes.Status200OK, response.StatusCode);
        }