"""http.py. Http utility class for API testing. """ from images.constants import header def get_valid_header_dict(): """Get a typical valid set of HTTP headers for a call to this API. Returns: Response: Response containing the created product. """ return {header.CONTENT_TYPE: header.APPLICATION_JSON} def get_valid_header_dict_with_cookie(cookies): """Get a typical valid set of HTTP headers for a call to this API. Args: cookies (str): the contents of the cookie header param Returns: Response: Response containing the created product. """ return {header.CONTENT_TYPE: header.APPLICATION_JSON, header.COOKIE: cookies}