public void When_LeagueNameIsEmpty_Then_ValidationError() { var query = new GetPlayerForTeamCompetitorQuery { LeagueName = "" }; var validator = new GetPlayerForTeamCompetitorQueryValidator(); validator.ShouldHaveValidationErrorFor(x => x.LeagueName, query); }
public void When_PlayerNameIsEmpty_Then_ValidationError() { var query = new GetPlayerForTeamCompetitorQuery { LeagueName = "Premier League", TeamName = "Tottenham Hotspur", PlayerName = "" }; var validator = new GetPlayerForTeamCompetitorQueryValidator(); validator.ShouldHaveValidationErrorFor(x => x.PlayerName, query); }