Beispiel #1
0
        public void TestTiltMeterValueIsIncreasedWhenPotWasBetween50and100BBPlayerLost(bool usePlusOperator)
        {
            var playerstatistic1 = new Playerstatistic();

            var playerstatistic2 = new Playerstatistic
            {
                Pot          = 1000,
                BigBlind     = 20,
                PlayerFolded = true,
                Wonhand      = 0
            };

            if (usePlusOperator)
            {
                playerstatistic1 += playerstatistic2;
            }
            else
            {
                playerstatistic1.Add(playerstatistic2);
            }

            var tiltMeter = playerstatistic1.TiltMeterTemporaryHistory.Dequeue();

            Assert.That(tiltMeter, Is.EqualTo(1));
        }
Beispiel #2
0
        public void TestTiltMeterValueIsIncreasedWhenFivePFRInRow(bool usePlusOperator)
        {
            var playerstatistic1 = new Playerstatistic();

            for (var i = 0; i < 5; i++)
            {
                var playerstatistic2 = new Playerstatistic
                {
                    Pfrhands = 1
                };

                if (usePlusOperator)
                {
                    playerstatistic1 += playerstatistic2;
                }
                else
                {
                    playerstatistic1.Add(playerstatistic2);
                }
            }

            var tiltMeter = playerstatistic1.TiltMeterTemporaryHistory.Last();

            Assert.That(tiltMeter, Is.EqualTo(2));
        }
Beispiel #3
0
        public void TestTiltMeterValueIsIncreasedIfPlayerSawShowdownButLost(bool usePlusOperator)
        {
            var playerstatistic1 = new Playerstatistic();

            var playerstatistic2 = new Playerstatistic
            {
                Sawshowdown = 1,
                Wonhand     = 0,
                Wonshowdown = 0
            };

            if (usePlusOperator)
            {
                playerstatistic1 += playerstatistic2;
            }
            else
            {
                playerstatistic1.Add(playerstatistic2);
            }

            Assert.That(playerstatistic1.TiltMeterPermanent, Is.EqualTo(1));
        }
Beispiel #4
0
        public void TestTiltMeterValueIsIncreasedIfPlayerSawFlopButFolded(bool usePlusOperator)
        {
            var playerstatistic1 = new Playerstatistic();

            var playerstatistic2 = new Playerstatistic
            {
                Sawflop      = 1,
                PlayerFolded = true
            };

            if (usePlusOperator)
            {
                playerstatistic1 += playerstatistic2;
            }
            else
            {
                playerstatistic1.Add(playerstatistic2);
            }

            var tiltMeter = playerstatistic1.TiltMeterTemporaryHistory.Dequeue();

            Assert.That(tiltMeter, Is.EqualTo(1));
        }