-
Notifications
You must be signed in to change notification settings - Fork 2
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
Feature/boolean voting #56
Conversation
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferencesYou may notice some variations in coverage metrics with the latest Coverage engine update. For more details, visit the documentation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not find the feature to be fully ready yet. Apart from the comments and suggestions I left, I also would like to remind you that for this feature to be considered complete it must handle a vote coming through store/views.py > post, which is the function responsible for registering users votes. I do not see that either
On another note, I would prefer if you guys followed the issue management corrently, I do not see any feature issue associated to this PR, but I saw 2 bug issues corresponding to problems found while working on this that only apply to your branch because it has to with how YOUR implemented feature does not integrate correctly other features. Those are not bugs, they are problems within your feature and should be discussed in the feature issue or in this PR if those problems are found by a reviewer. Please take note for the next time.
Now the issue of handling a vote in store > views.py should be solved. Please review the code again when you can. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay I now understand the particularities of the tests, I still don't like the way the question options are handled in the admin page but that can be dealt with at a later point.
Anyways, good job!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The tests run correctly and the functionality works. Good job!
This Pull Request aims to add a boolean type to questions, i.e. questions with simple "yes" and "no" options. It also includes unit tests. It might be necessary to migrate before running the application.
Unlike other question types, this one creates its options automatically upon creating it with no options and doesn't allow any other options. This will be indicated in a BadRequest error when trying to add them.
This type is also compatible with blank voting, creating a third "blank vote" option in that case.