def test_calls_throw_on_game_with_integer_of_number_of_pins_entered(self, input_mock): input_mock.return_value = "10" game = mock.Mock(spec_set=BowlingGame) lane = BowlingLane() lane._get_throw(game) game.throw.assert_called_once_with(10)
def test_prompts_for_user_throw(self, input_mock): input_mock.return_value = "0" lane = BowlingLane() lane._get_throw(mock.Mock(spec_set=BowlingGame)) input_mock.assert_called_with(THROW_BALL_PROMPT)