Skip to content
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

Fix BF Exact Change Tests #3621

Merged

Conversation

ltegman
Copy link
Member

@ltegman ltegman commented Oct 7, 2015

Added a test case for when the smallest denomination of change available is larger than the total change required.

Closes #1409

Added a test case for when the smallest denomination of change available is larger than the total change required.

Closes freeCodeCamp#1409
@ahstro
Copy link
Member

ahstro commented Oct 8, 2015

Thank you for this, but you need to add a large value as well, e.g. ONE HUNDRED, to make sure that the code written says Insufficient Funds even if there is enough money, just not enough change.

@ahstro ahstro added the status: blocked Is waiting on followup from either the Opening Poster of the issue or PR, or a maintainer. label Oct 8, 2015
@ltegman
Copy link
Member Author

ltegman commented Oct 8, 2015

The test case I included should only return .5 of change and the available dollar in the drawer is valued at 1.00 so I think this should correctly test the case where the value of the total change is high enough but the denomination is too high and should return Insufficient Funds. I'm happy to change the case though if you think that's not correct.

@ahstro
Copy link
Member

ahstro commented Oct 8, 2015

Oh, duh, my brain is apparenlty mush. My code worked, but I didn't think it was supposed to.. Let me do some more testing.

@ahstro
Copy link
Member

ahstro commented Oct 8, 2015

Didn't expect my old code to work, I guess I just wrote better code than I though back when I solved this. Thank you :)

ahstro pushed a commit that referenced this pull request Oct 8, 2015
@ahstro ahstro merged commit 9423c1c into freeCodeCamp:staging Oct 8, 2015
@dcsan dcsan removed the status: blocked Is waiting on followup from either the Opening Poster of the issue or PR, or a maintainer. label Oct 8, 2015
@ltegman ltegman deleted the fix/bonfire-exact-change-add-tests-1409 branch October 19, 2015 19:12
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.

None yet

3 participants