private void AnalyzeAndShowBets()
        {
            IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
            var customersWithStatistics = betsAnalyzer.GetCustomersStatistics(SettledBets);
            var unUsualCustomers = betsAnalyzer.FindUnusualCustomers(customersWithStatistics);
            var riskyBets = betsAnalyzer.FindRiskyBets(unUsualCustomers, UnsettledBets);
            var unUsualBets = betsAnalyzer.FindUnusualBets(customersWithStatistics, UnsettledBets);
            var highlyUnusualBets = betsAnalyzer.FindHighlyUnusualBets(customersWithStatistics, UnsettledBets);
            var unusualWinningBets = betsAnalyzer.FindUnusualWinningBets(UnsettledBets);

            gridUnusualCustomers.DataSource = unUsualCustomers;
            gridRiskyBets.DataSource = riskyBets;
            gridUsualBets.DataSource = unUsualBets;
            gridHighlyUnusualBets.DataSource = highlyUnusualBets;
            gridUnusualWinningBets.DataSource = unusualWinningBets;
            gridAllCustomers.DataSource = customersWithStatistics;
            gridAllSettledBets.DataSource = SettledBets;
            gridAllUnsettledBets.DataSource = UnsettledBets;
        }
 public void Test_GetCustomersStatistics()
 {
     IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
     var customers = betsAnalyzer.GetCustomersStatistics(settledBets);
     Assert.AreEqual(customers.Count, 2);
 }
 public void Test_FindUnusualWinningBets()
 {
     IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
     var highllyUnusualBets = betsAnalyzer.FindUnusualWinningBets(unsettledBets);
     Assert.AreEqual(highllyUnusualBets.Count, 1);
 }
 public void Test_FindUnusualCustomers()
 {
     IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
     var unusualCustomers = betsAnalyzer.FindUnusualCustomers(customers);
     Assert.AreEqual(unusualCustomers.Count, 1);
 }
 public void Test_FindUnusualBets()
 {
     IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
     var unusualBets = betsAnalyzer.FindUnusualBets(customers, unsettledBets);
     Assert.AreEqual(unusualBets.Count, 0);
 }
 public void Test_FindRiskyBets()
 {
     IBetsAnalyzer betsAnalyzer = new BetsAnalyzer();
     var riskyBets = betsAnalyzer.FindRiskyBets(unusualCustomers, unsettledBets);
     Assert.AreEqual(riskyBets.Count, 1);
 }