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

Add initial position value #5

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

Bcow7
Copy link

@Bcow7 Bcow7 commented Feb 6, 2020

No description provided.

@raphaelyancey
Copy link
Owner

Thanks for the PR @Bcow7!

Is there a reason you got rid of this line ? If you don't use initial_pos then you still would want it to be set to a default.

@Bcow7
Copy link
Author

Bcow7 commented Feb 10, 2020

You are right. I missed the default value

@raphaelyancey
Copy link
Owner

My bad, that's on me — self.counter is initialized to 0 at the instanciation. So you were right, you can get rid of the line.

Since your first commit I've added tests. Could you add a few lines for this new param? Also we need to assert self.initial_pos >= self.min_counter and self.initial_pos <= self.max_counter in the lib, and your test would check that it is enforced. You can create a new test function I think, because anyway I need to add tests for all those type assertions.

If you don't have time for this I'll do it, just tell me! Sorry for those back-and-forth I'm kind of new to managing PRs ;)

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