def test_process_response_imgs(self): host_url = 'http://www.davidcmoss.co.uk/' content = "<img src='test.png' />" response = Response() response.url = host_url response._content = content page = process_response(host_url, response) assert host_url + 'test.png' in page.images
def test_process_response_ex_links(self): host_url = 'http://www.davidcmoss.co.uk/' content = "<a href='http://google.com' />" response = Response() response.url = host_url response._content = content page = process_response(host_url, response) assert 'http://google.com' in page.ex_links
def test_process_response_links(self): host_url = 'http://www.davidcmoss.co.uk/' content = "<a href='/test' />" response = Response() response.url = host_url response._content = content page = process_response(host_url, response) assert host_url + 'test' in page.links