Beispiel #1
0
        public void When_LeagueNameIsEmpty_Then_ValidationError()
        {
            var command = new UpdateTeamLeagueMatchLineupEntryCommand
            {
                LeagueName = ""
            };

            var validator = new UpdateTeamLeagueMatchLineupEntryCommandValidator();

            validator.ShouldHaveValidationErrorFor(x => x.LeagueName, command);
        }
Beispiel #2
0
        public void When_MatchGuidIsEmpty_Then_ValidationError()
        {
            var command = new UpdateTeamLeagueMatchLineupEntryCommand
            {
                LeagueName = "Premier League",
                MatchGuid  = Guid.Empty
            };

            var validator = new UpdateTeamLeagueMatchLineupEntryCommandValidator();

            validator.ShouldHaveValidationErrorFor(x => x.MatchGuid, command);
        }
Beispiel #3
0
        public void When_LineupEntryGuidIsEmpty_Then_ValidationError()
        {
            var command = new UpdateTeamLeagueMatchLineupEntryCommand
            {
                LeagueName      = "Premier League",
                MatchGuid       = Guid.NewGuid(),
                TeamName        = "Tottenham Hotspur",
                LineupEntryGuid = Guid.Empty
            };

            var validator = new UpdateTeamLeagueMatchLineupEntryCommandValidator();

            validator.ShouldHaveValidationErrorFor(x => x.LineupEntryGuid, command);
        }