예제 #1
0
        public IActionResult DeleteAccount([FromRoute(Name = "accountId")][Required] string accountId)
        {
            string clientId = Request.HttpContext.Items["ClientId"]?.ToString();

            if (_accountProcessor.DeleteAccount(accountId, clientId))
            {
                return(Json("Account Deleted"));
            }
            return(BadRequest("Failed to delete Account"));
        }
예제 #2
0
        public void DeleteAccount()
        {
            // Arrange
            Guid accountId = new Guid("67B81996-B226-E711-810C-5065F38A2B61");
            bool response  = false;

            // Act
            response = _processor.DeleteAccount(accountId);

            // Assert
            Assert.IsTrue(response);
        }