public void TestAllocation() { var msg = new PlayerGameProjectionMessage {Game = new NFLGame( "2013:01-B" )}; var sut = new GetGamePrediction( msg ); Assert.IsNotNull( msg.Prediction ); Utility.Announce( msg.Prediction.PredictedScore() ); var sut2 = new PullMetricsFromPrediction( msg ); Assert.IsNotNull( msg.Game.PlayerGameMetrics ); var sut3 = new SavePlayerGameMetrics(msg); }
public void TestJayCutler() { var g = new NFLGame( "2016:01-I" ); var msg = new PlayerGameProjectionMessage(); msg.Player = new NFLPlayer( "CUTLJA01" ); msg.Game = g; msg.Prediction = g.GetPrediction( "unit" ); var cut = new PullMetricsFromPrediction( msg ); Assert.IsNotNull( msg.Game.PlayerGameMetrics.Count > 12 ); msg.Dao = new DbfPlayerGameMetricsDao(); var saveStep = new SavePlayerGameMetrics( msg ); }
public void TestASavingMetrics() { var msg = new PlayerGameProjectionMessage {Game = new NFLGame( "2013:01-B" )}; var sut = new GetGamePrediction( msg ); var sut2 = new PullMetricsFromPrediction( msg ); var sut3 = new SavePlayerGameMetrics( msg ); var dpgmDoa = new DbfPlayerGameMetricsDao(); var pgmList = msg.Game.PlayerGameMetrics; var expectedPgm = pgmList.FirstOrDefault(); var pgm = dpgmDoa.Get( expectedPgm.PlayerId, expectedPgm.GameKey ); Assert.IsNotNull( pgm ); }