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

Test QueryDict against CSV filters #937

Merged
merged 2 commits into from
Jul 13, 2018

Conversation

rpkilby
Copy link
Collaborator

@rpkilby rpkilby commented Jul 3, 2018

Verify expected behavior from #935. Essentially, the CSV filters should treat:

MyAPI/mymodel?mysubmodel__in=1&mysubmodel__in=5&mysubmodel__in=9

as equivalent to:

MyAPI/mymodel?mysubmodel__in=9
  • Refactors tests to use Python 3's subTest feature.
  • Updates tests to test against expected IDs instead of just a count.
  • Adds a QueryDict case to test the above expected behavior.

@codecov-io
Copy link

codecov-io commented Jul 3, 2018

Codecov Report

Merging #937 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #937   +/-   ##
=======================================
  Coverage   97.95%   97.95%           
=======================================
  Files          15       15           
  Lines        1122     1122           
=======================================
  Hits         1099     1099           
  Misses         23       23

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b1f1c65...5d26ba4. Read the comment docs.

@carltongibson carltongibson added this to the Version 2.0 milestone Jul 13, 2018
Copy link
Owner

@carltongibson carltongibson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine.

Why do they take the last value (rather than the first say?)

(I have no issue with it either way: it's not the intended usage for CSV widgets...)

@carltongibson carltongibson merged commit f81af87 into carltongibson:master Jul 13, 2018
@rpkilby rpkilby deleted the test-csv-params branch July 13, 2018 13:18
@rpkilby
Copy link
Collaborator Author

rpkilby commented Jul 13, 2018

Why do they take the last value (rather than the first say?)

I honestly have no idea.

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.

3 participants