#NEWLINE# def assert_download_response( test_case , response , **assertions ) : #NEWLINE# #INDENT# 'Make ``test_case`` assert that ``response`` meets ``assertions``.\n\n    Optional ``assertions`` dictionary can be used to check additional items:\n\n    * ``basename``: the basename of the file in the response.\n\n    * ``content_type``: the value of "Content-Type" header.\n\n    * ``mime_type``: the MIME type part of "Content-Type" header (without\n      charset).\n\n    * ``content``: the contents of the file.\n\n    * ``attachment``: whether the file is returned as attachment or not.\n\n    ' #NEWLINE# validator = DownloadResponseValidator ( ) #NEWLINE# return validator ( test_case , response , ** assertions )