def test_elem_non_ads(): match = abparser.lookup() for elem in elem_non_ads: # returns false in an array if found for individual elem assert match.match_elem("class", elem) == [False]
def test_non_ad_url(): match = abparser.lookup() for url in url_non_ads: # returns none if no matches are found assert match.match_url(url) == None
def test_elem_ads(): match= abparser.lookup() for elem in elem_ads: # returns true in an array if found for each individual elem assert match.match_elem("class", elem) == [True]
def test_ad_url(): match = abparser.lookup() for url in url_ads: # returns true if match is found assert match.match_url(url) == True