Example #1
0
 public void Properly_constructed_FieldGoal_gives_a_proper_FG()
 {
     _playFactory.NewPlay(_playerA, true);
     _playFactory.ChoosePlayType(PlayType.FieldGoal);
     _playFactory.SelectPoints("3");
     _playFactory.FGResult("Make");
     Assert.Multiple(() =>
     {
         var _plays = _playFactory.GetPlays();
         Assert.AreEqual(1, _plays.Count);
         var _play = _plays.First();
         Assert.AreEqual(_playerA, _play.Player);
         Assert.AreEqual(true, _play.TeamB);
         Assert.AreEqual(3, _play.Points);
     });
 }
        private void FieldGoalOutcome(string outcome)
        {
            ChooseFieldGoalOutcomeVisibility = Visibility.Collapsed;
            _playFactory.FGResult(outcome);
            switch (outcome)
            {
            case "Make":
                MadeFieldGoal();
                break;

            case "Miss":
                MissedFieldGoal();
                break;

            case "Block":
                BlockedFieldGoal();
                break;
            }
        }