예제 #1
0
        public async Task Post_Returns_NotFoundWhenReceiverDoesNotExist()
        {
            // Arrange
            _managerMock.Setup(m => m.GetReceiver(TestReceiver))
            .Returns((IWebHookReceiver)null)
            .Verifiable();

            // Act
            IHttpActionResult result = await _controller.Post(TestReceiver);

            // Assert
            _managerMock.Verify();
            Assert.IsType <NotFoundResult>(result);
        }
예제 #2
0
 public Task Post_Returns_NotFoundWhenReceiverDoesNotExist()
 {
     return(Action_Returns_NotFoundWhenReceiverDoesNotExist(rec => _controller.Post(rec)));
 }