public void ThenAnOkResultShouldBeReturned()
        {
            var result = _controller.Get();

            Assert.That(result, Is.Not.Null);
            Assert.That(result, Is.TypeOf <OkResult>());
        }
        public void TestPingGetPong()
        {
            var pingController = new PingController();
            var result         = pingController.Get();

            Assert.AreEqual("Pong", result.Value);
        }
Example #3
0
        public void Get_ReturnsPong()
        {
            var sut = new PingController();

            var returned = sut.Get();

            Assert.Equal("Pong!", returned);
        }
        public void GetAllUsersTest()
        {
            //act
            var pingController = new PingController(_mokuserDetailLogic.Object);
            var detail         = pingController.Get();

            //assert
            Assert.AreEqual("Pinged successfully!", detail);
        }
Example #5
0
        public void Get_ReturnsPong()
        {
            // given
            var controller = new PingController();

            // when
            var result = controller.Get();

            // then
            result.Should().Be("pong");
        }