Example #1
0
        public void UpdateWith_EmptyList_AllMatchingPlayersAreEmpty()
        {
            var sut = new PostFlopHeroXStatistic(Streets.Flop, false);

            sut.UpdateWith(_analyzablePokerPlayers);

            foreach (var matchingPlayer in sut.MatchingPlayers)
            {
                matchingPlayer.ShouldBeEmpty();
            }
        }
Example #2
0
        public void UpdateWith_OneMatchingPlayer_MatchingPlayersForGivenBetSizeContainPlayer()
        {
            const long    id         = 1;
            const bool    inPosition = false;
            const Streets street     = Streets.Flop;

            var sut = new PostFlopHeroXStatistic(street, inPosition);

            var player = Samples.AnalyzablePokerPlayerWith(id, ActionSequences.HeroX, street, inPosition);

            _analyzablePokerPlayers.Add(player);

            sut.UpdateWith(_analyzablePokerPlayers);

            sut.MatchingPlayers[0].ShouldContain(player);
        }
Example #3
0
        public void UpdateWith_TwoPlayersOneMatchingPlayer_MatchingPlayersDoNotContainNotMatchingPlayer()
        {
            const long    id         = 1;
            const bool    inPosition = false;
            const Streets street     = Streets.Flop;

            var sut = new PostFlopHeroXStatistic(street, inPosition);

            var matchingPlayer    = Samples.AnalyzablePokerPlayerWith(id, ActionSequences.HeroX, street, inPosition);
            var notMatchingPlayer = Samples.AnalyzablePokerPlayerWith(id + 1, ActionSequences.HeroX + 1, street, inPosition);

            _analyzablePokerPlayers.Add(matchingPlayer);
            _analyzablePokerPlayers.Add(notMatchingPlayer);

            sut.UpdateWith(_analyzablePokerPlayers);

            sut.MatchingPlayers[0].ShouldNotContain(notMatchingPlayer);
        }
Example #4
0
        public void UpdateWith_PlayerWithHeroXOppBHeroReacts_PlayerIsIncludedInMatchingPlayers(
            [Values(ActionSequences.HeroXOppBHeroF, ActionSequences.HeroXOppBHeroC, ActionSequences.HeroXOppBHeroR)]
            ActionSequences actionSequence)
        {
            const long    id         = 1;
            const bool    inPosition = false;
            const Streets street     = Streets.Flop;

            var sut = new PostFlopHeroXStatistic(street, inPosition);

            var player = Samples.AnalyzablePokerPlayerWith(id, actionSequence, street, inPosition);

            _analyzablePokerPlayers.Add(player);

            sut.UpdateWith(_analyzablePokerPlayers);

            sut.MatchingPlayers[0].ShouldContain(player);
        }