def METHOD_NAME(self):
    """Test the do_search function, including the outgoing search term and
    search history."""
    old_token = core.search.token
    # Try a search with special characters removed
    config.sections["searches"]["remove_special_chars"] = True
    search_term, search_term_without_special, *_unused = core.search.process_search_term(SEARCH_TEXT, SEARCH_MODE)
    core.search.do_search(SEARCH_TEXT, SEARCH_MODE)
    self.assertEqual(core.search.token, old_token + 1)
    self.assertEqual(search_term, "70 gwen test a b c d auto yes -mp3 -nothanks *ello -no")
    self.assertEqual(search_term_without_special, "70 gwen test a b c d auto yes")
    self.assertEqual(config.sections["searches"]["history"][0], search_term)
    # Try a search without special characters removed
    config.sections["searches"]["remove_special_chars"] = False
    search_term, search_term_without_special, *_unused = core.search.process_search_term(SEARCH_TEXT, SEARCH_MODE)
    core.search.do_search(SEARCH_TEXT, SEARCH_MODE)
    self.assertEqual(search_term, '70 gwen "test" a:b;c+d +++---}[ [[ @@ auto yes -mp3 -nothanks *ello -no')
    self.assertEqual(search_term_without_special, '70 gwen "test" a:b;c+d +++---}[ [[ @@ auto yes')
    self.assertEqual(config.sections["searches"]["history"][0], search_term)
    self.assertEqual(config.sections["searches"]["history"][1],
                     "70 gwen test a b c d auto yes -mp3 -nothanks *ello -no")