public void Test_CreatePlayer_InvalidUsername_RespondsFail() { var request = new CreatePlayerMessages.Request() { Username = "", Password = "" }; var response = interactor.Handle(request); Assert.IsFalse(response.Success); request.Username = String.Empty; var response2 = interactor.Handle(request); Assert.IsFalse(response2.Success); }
public string Post(string username, string password) { var request = new CreatePlayerMessages.Request() { Username = username, Password = password }; var response = interator.Handle(request); var jsonResponse = JsonConvert.SerializeObject(response); return(jsonResponse); }