def METHOD_NAME(self):
    """Check if the http status is what we expected."""
    path_to_statuses = {
        '/favicon.ico': [
            HTTPStatus.OK,
            HTTPStatus.PARTIAL_CONTENT,
            HTTPStatus.NOT_MODIFIED,
        ],
        '/does-not-exist': [HTTPStatus.NOT_FOUND],
        '/does-not-exist-2': [HTTPStatus.NOT_FOUND],
        '/404': [HTTPStatus.NOT_FOUND],
        '/redirect-later': [HTTPStatus.FOUND],
        '/redirect-self': [HTTPStatus.FOUND],
        '/redirect-to': [HTTPStatus.FOUND],
        '/relative-redirect': [HTTPStatus.FOUND],
        '/absolute-redirect': [HTTPStatus.FOUND],
        '/redirect-http/data/downloads/download.bin': [HTTPStatus.FOUND],
        '/cookies/set': [HTTPStatus.FOUND],
        '/cookies/set-custom': [HTTPStatus.FOUND],
        '/500-inline': [HTTPStatus.INTERNAL_SERVER_ERROR],
        '/500': [HTTPStatus.INTERNAL_SERVER_ERROR],
    }
    for i in range(25):
        path_to_statuses['/redirect/{}'.format(i)] = [HTTPStatus.FOUND]
    for suffix in ['', '1', '2', '3', '4', '5', '6']:
        key = ('/basic-auth/user{suffix}/password{suffix}'
               .format(suffix=suffix))
        path_to_statuses[key] = [HTTPStatus.UNAUTHORIZED, HTTPStatus.OK]
    default_statuses = [HTTPStatus.OK, HTTPStatus.NOT_MODIFIED]
    sanitized = QUrl('http://localhost' + self.path).path()  # Remove ?foo
    expected_statuses = path_to_statuses.get(sanitized, default_statuses)
    if self.status not in expected_statuses:
        raise AssertionError(
            "{} loaded with status {} but expected {}".format(
                sanitized, self.status,
                ' / '.join(repr(e) for e in expected_statuses)))