public void TestAllPositionsCurrentWeekYahoo() { var sut = new PerformanceReportGenerator(new TimeKeeper(null) ); var master = new YahooMaster( "Yahoo", "YahooOutput.xml" ); var theSeason = Int32.Parse( Utility.CurrentSeason() ); var weekIn = Utility.PreviousWeek(); var theWeek = new NFLWeek( theSeason, weekIn: weekIn, loadGames: false ); var gs = new EspnScorer( theWeek ) {Master = master, AnnounceIt = true}; //var rpt = new PerformanceReportConfig { // Category = Constants.K_QUARTERBACK_CAT, Position = "QB", Scorer = gs, Week = theWeek }; foreach ( var rpt in sut.Configs ) { sut.GenerateReport( rpt, Constants.K_LEAGUE_Yahoo ); } }
public void TestGoBackOneMonth() { var sut = new PerformanceReportGenerator(new TimeKeeper(null) ); var master = new YahooMaster( "Yahoo", "YahooOutput.xml" ); var theSeason = Int32.Parse( Utility.CurrentSeason() ); var weekIn = Utility.PreviousWeek(); var theWeek = new NFLWeek( theSeason, weekIn: weekIn, loadGames: false ); var gs = new EspnScorer( theWeek ) { Master = master, AnnounceIt = true }; var configs = new List<PerformanceReportConfig>(); var rpt = new PerformanceReportConfig { Category = Constants.K_QUARTERBACK_CAT, Position = "QB", Scorer = gs, Week = theWeek, WeeksToGoBack = 4 }; configs.Add( rpt ); sut.Configs = configs; // overwrite the default configs foreach ( var r in sut.Configs ) { sut.GenerateReport( r, Constants.K_LEAGUE_Yahoo ); } }