Esempio n. 1
0
        public void TestPredefinedNotes(string handHistoryFile, EnumPokerSites pokerSite, string playerName, string noteName, bool expected)
        {
            var handHistoryObject = CreateHandHistoryObject(handHistoryFile, pokerSite, playerName);

            var noteProcessingService = new NoteProcessingService();

            var note = ReadNote(noteName);

            Assert.IsNotNull(note, $"Note [{noteName}] must be in predefined data set.");

            var playernotes = noteProcessingService.ProcessHand(new[] { note }, handHistoryObject.Stat, handHistoryObject.HandHistory);

            Assert.IsNotNull(playernotes, "Notes must be not null");
            Assert.That(playernotes.Any(), Is.EqualTo(expected));
        }
Esempio n. 2
0
        public void TestSecondPreflopPlayerAction(string handHistoryFile, EnumPokerSites pokerSite, string playerName, ActionTypeEnum actionType, double min, double max, bool expected)
        {
            var handHistoryObject = CreateHandHistoryObject(handHistoryFile, pokerSite, playerName);

            var note = new NoteObject();

            note.Settings.PreflopActions.SecondType     = actionType;
            note.Settings.PreflopActions.SecondMaxValue = max;
            note.Settings.PreflopActions.SecondMinValue = min;

            var noteProcessingService = new NoteProcessingService();

            var playernotes = noteProcessingService.ProcessHand(new[] { note }, handHistoryObject.Stat, handHistoryObject.HandHistory);

            Assert.IsNotNull(playernotes, "Notes must be not null");
            Assert.That(playernotes.Any(), Is.EqualTo(expected));
        }