statgen / bravo_api

Server side data processing and retrieval endpoints for BRAVO
MIT License
1 stars 2 forks source link

Refactor an put under test `deserialize_query_filter` #12

Open grosscol opened 2 years ago

grosscol commented 2 years ago

Issue or current state

The function parses a string into a dictionary suitable for passing to mongo as a filter. It is not a difficult read, but could use some tests to illustrate the expected behavior. It might benefit from being refactored into smaller functions that themselves can be tested

Resolved when

deserialize_query_filter is under test, and a is_value_a_quoted_string function exists under test as well.

grosscol commented 1 year ago

deserialize_query_filter has been superceded by munge_ui_filters. Still remains to be put under test to illustrate what it's doing more clearly.