X-Git-Url: https://git.rapsys.eu/youtubedl/blobdiff_plain/9815bb0a551468e4939cacfffbc2d5cb8dd12431..67792219d78d4576f8281748a441d056fa6fdb93:/youtube_dl/extractor/facebook.py

diff --git a/youtube_dl/extractor/facebook.py b/youtube_dl/extractor/facebook.py
index c694f9a..9d1bc07 100644
--- a/youtube_dl/extractor/facebook.py
+++ b/youtube_dl/extractor/facebook.py
@@ -22,6 +22,15 @@ class FacebookIE(InfoExtractor):
     _LOGIN_URL = 'https://login.facebook.com/login.php?m&next=http%3A%2F%2Fm.facebook.com%2Fhome.php&'
     _NETRC_MACHINE = 'facebook'
     IE_NAME = u'facebook'
+    _TEST = {
+        u'url': u'https://www.facebook.com/photo.php?v=120708114770723',
+        u'file': u'120708114770723.mp4',
+        u'md5': u'48975a41ccc4b7a581abd68651c1a5a8',
+        u'info_dict': {
+            u"duration": 279, 
+            u"title": u"PEOPLE ARE AWESOME 2013"
+        }
+    }
 
     def report_login(self):
         """Report attempt to log in."""
@@ -97,8 +106,8 @@ class FacebookIE(InfoExtractor):
         video_duration = int(video_data['video_duration'])
         thumbnail = video_data['thumbnail_src']
 
-        video_title = self._html_search_regex('<h2 class="uiHeaderTitle">([^<]+)</h2>',
-            webpage, u'title')
+        video_title = self._html_search_regex(
+            r'<h2 class="uiHeaderTitle">([^<]*)</h2>', webpage, u'title')
 
         info = {
             'id': video_id,