Skip to content

[Bowling] Add edge case with fill balls in a last-frame strike (Re-applies #418) #423

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 22, 2016

Conversation

Insti
Copy link
Contributor

@Insti Insti commented Oct 22, 2016

Fixes the mess I made of @IanWhitney's PR: #418

  • Add edge case with fill balls in a last-frame strike

The previous test does not quite capture the behavior.

If the first fill fill is a non-strikes, then the total fill-ball score
must be less than 10.

But, if the first fill ball is a strike, then the total fill-ball score
must be less than 20. Because that first fill-ball strike resets the
pins.

I had what I thought was a working implementation but it totally missed
the 2nd case. Adding a test to cover that case.

  • Add edge case test for final-strike fill balls

This test checks that the fill balls validate correctly if the 2nd ball
is a strike.

…ism#418)

* Add edge case with fill balls in a last-frame strike

The previous test does not quite capture the behavior.

If the first fill fill is a non-strikes, then the total fill-ball score
must be less than 10.

But, if the first fill ball is a strike, then the total fill-ball score
must be less than 20. Because that first fill-ball strike resets the
pins.

I had what I thought was a working implementation but it totally missed
the 2nd case. Adding a test to cover that case.

* Add edge case test for final-strike fill balls

This test checks that the fill balls validate correctly if the 2nd ball
is a strike.
@Insti Insti changed the title [Bowling] Add edge case with fill balls in a last-frame strike (#418) [Bowling] Add edge case with fill balls in a last-frame strike (Re-applies #418) Oct 22, 2016
@Insti Insti merged commit 7b0949e into exercism:master Oct 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants