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 a broken unit test (#3) #4

Merged
merged 1 commit into from
Feb 8, 2020

Conversation

mearns
Copy link
Contributor

@mearns mearns commented Sep 28, 2018

Ensures length is not negative. This can happen when finish and start are 0, and step is -1. Length should be 0, but is calculated as -0.

This is strange behavior, and also caused a unit test to fail because the generated array length was 0, which
did not assert as equal to the calculated range length or -0.

Fixes issue #3.

This can happen when finish and start are 0, and step is -1. Length should be 0, but is calculated as -0.
This is strange behavior, and caused a unit test to fail because the generated array length was 0, which
did not assert as equal to the calculated range length or -0.
@gyllstromk gyllstromk merged commit 42d93f3 into gyllstromk:master Feb 8, 2020
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