]>
Raphaƫl G. Git Repositories - youtubedl/blob - test/test_postprocessors.py
3 from __future__
import unicode_literals
5 # Allow direct execution
9 sys
.path
.insert(0, os
.path
.dirname(os
.path
.dirname(os
.path
.abspath(__file__
))))
11 from youtube_dl
.postprocessor
import MetadataFromTitlePP
14 class TestMetadataFromTitle(unittest
.TestCase
):
15 def test_format_to_regex(self
):
16 pp
= MetadataFromTitlePP(None, '%(title)s - %(artist)s')
17 self
.assertEqual(pp
._titleregex
, '(?P<title>.+)\ \-\ (?P<artist>.+)')