date__gt, date__lt can be datetime.date objects; added tests for build_search_query