public void IfCreatingAPasswordSucceedsResultIsJsonSuccessResponse(PasswordResetCreationResult result)
        {
            GivenThatCreatingAPasswordResetReturns(result);
            var response = Browser.Post("/api/user/passwordreset", with => with.FormValue("username", Username));

            ThenJsonResponse(response)
                .IsFailure();
        }
 private void GivenThatCreatingAPasswordResetReturns(PasswordResetCreationResult mockedResult)
 {
     Models.Setup(m => m.User.CreatePasswordReset(Username)).Returns(mockedResult);
 }