def test_bad_content_link_removed(self): link_string = "Wrong!\n\n**[Watch video to review](https://www.khanacademy.org/humanities/art-history/v/the-penguin-king-has-risen)**\n\nThat's a wrap!" expected_string = "Wrong!\n\n\n\nThat's a wrap!" assert expected_string == localize_content_links( {"item_data": link_string})["item_data"]
def test_bad_content_link_removed(self): link_string = "Wrong!\n\n**[Watch video to review](https://www.khanacademy.org/humanities/art-history/v/the-penguin-king-has-risen)**\n\nThat's a wrap!" expected_string = "Wrong!\n\n\n\nThat's a wrap!" assert expected_string == localize_content_links({"item_data": link_string})["item_data"]
def test_content_link_converted(self): link_string = "(and so that is the correct answer).**\\n\\n[Watch this video to review](https://www.khanacademy.org/humanities/history/ancient-medieval/Ancient/v/standard-of-ur-c-2600-2400-b-c-e)" expected_string = "(and so that is the correct answer).**\\n\\n[Watch this video to review](/learn/khan/test-prep/ap-art-history/ancient-mediterranean-AP/ancient-near-east-a/standard-of-ur-c-2600-2400-b-c-e/)" assert expected_string == localize_content_links( {"item_data": link_string})["item_data"]
def test_content_link_converted(self): link_string = "(and so that is the correct answer).**\\n\\n[Watch this video to review](https://www.khanacademy.org/humanities/history/ancient-medieval/Ancient/v/standard-of-ur-c-2600-2400-b-c-e)" expected_string = "(and so that is the correct answer).**\\n\\n[Watch this video to review](/learn/khan/test-prep/ap-art-history/ancient-mediterranean-AP/ancient-near-east-a/standard-of-ur-c-2600-2400-b-c-e/)" assert expected_string == localize_content_links({"item_data": link_string})["item_data"]