All tests re-enabled and passing

This commit is contained in:
Dylan
2023-07-02 18:19:14 +01:00
parent c99f3de6c1
commit abedae385c
2 changed files with 22 additions and 17 deletions

View File

@ -106,12 +106,11 @@ def test_pollTweetExtract():
tweet = twExtract.extractStatus("https://twitter.com/norm/status/651169346518056960")
assert 'card' in tweet
compareDict(testPoll_comparePoll,tweet['card'])
'''
def test_NSFW_TweetExtract():
tweet = twExtract.extractStatus(testNSFWTweet) # For now just test that there's no error
''' # this test currently fails due to new Twitter API restrictions
## VNF conversion test ##
## VNF conversion test ##
def test_textTweetVNF():
vnf = twitfix.link_to_vnf_from_unofficial_api(testTextTweet)
compareDict(textVNF_compare,vnf)
@ -194,12 +193,12 @@ def test_embedFromCache():
assert resp.status_code==200
resp = client.get(testMultiMediaTweet.replace("https://twitter.com",""),headers={"User-Agent":"test"})
assert resp.status_code==200
'''
def test_embedSuggestive():
resp = client.get(testNSFWTweet.replace("https://twitter.com",""),headers={"User-Agent":"test"})
assert resp.status_code==200
assert "so i had a bot generate it for me" in str(resp.data)
''' # this test currently fails due to new Twitter API restrictions
def test_veryLongEmbed():
cache.clearCache()
cache.setCache({'https://twitter.com/TEST/status/1234':