'artist': 'Hurts',
'genre': 'Pop',
},
- 'expected_warnings': ['Unable to download SMIL file'],
+ 'expected_warnings': ['Unable to download SMIL file', 'Unable to download info'],
}, {
'note': 'v3 SMIL format',
'url': 'http://www.vevo.com/watch/cassadee-pope/i-wish-i-could-break-your-heart/USUV71302923',
'artist': 'Cassadee Pope',
'genre': 'Country',
},
- 'expected_warnings': ['Unable to download SMIL file'],
+ 'expected_warnings': ['Unable to download SMIL file', 'Unable to download info'],
}, {
'note': 'Age-limited video',
'url': 'https://www.vevo.com/watch/justin-timberlake/tunnel-vision-explicit/USRV81300282',
'artist': 'Justin Timberlake',
'genre': 'Pop',
},
- 'expected_warnings': ['Unable to download SMIL file'],
+ 'expected_warnings': ['Unable to download SMIL file', 'Unable to download info'],
}, {
'note': 'No video_info',
'url': 'http://www.vevo.com/watch/k-camp-1/Till-I-Die/USUV71503000',
'artist': 'K Camp',
'genre': 'Hip-Hop',
},
+ 'expected_warnings': ['Unable to download SMIL file', 'Unable to download info'],
}, {
'note': 'Featured test',
'url': 'https://www.vevo.com/watch/lemaitre/Wait/USUV71402190',
'artist': 'Lemaitre',
'genre': 'Electronic',
},
+ 'expected_warnings': ['Unable to download SMIL file', 'Unable to download info'],
}, {
'note': 'Only available via webpage',
'url': 'http://www.vevo.com/watch/GBUV71600656',
note='Retrieving oauth token',
errnote='Unable to retrieve oauth token')
- if 'THIS PAGE IS CURRENTLY UNAVAILABLE IN YOUR REGION' in webpage:
+ if re.search(r'(?i)THIS PAGE IS CURRENTLY UNAVAILABLE IN YOUR REGION', webpage):
self.raise_geo_restricted(
'%s said: This page is currently unavailable in your region' % self.IE_NAME)
timestamp = parse_iso8601(video_info.get('releaseDate'))
artists = video_info.get('artists')
for curr_artist in artists:
- if 'role' in curr_artist:
- if curr_artist['role'] == 'Featured':
- featured_artist = curr_artist['name']
- elif curr_artist['role'] == 'Main':
- artist = uploader = curr_artist['name']
+ if curr_artist.get('role') == 'Featured':
+ featured_artist = curr_artist['name']
else:
artist = uploader = curr_artist['name']
- break
view_count = int_or_none(video_info.get('views', {}).get('total'))
for video_version in video_versions: