]> jfr.im git - yt-dlp.git/blame - test/test_postprocessors.py
[skip travis] renaming
[yt-dlp.git] / test / test_postprocessors.py
CommitLineData
88cf6fb3
JMF
1#!/usr/bin/env python
2
3from __future__ import unicode_literals
4
5# Allow direct execution
6import os
7import sys
8import unittest
9sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
10
cefecac1 11from youtube_dlc.postprocessor import MetadataFromTitlePP
88cf6fb3
JMF
12
13
14class TestMetadataFromTitle(unittest.TestCase):
15 def test_format_to_regex(self):
16 pp = MetadataFromTitlePP(None, '%(title)s - %(artist)s')
6864855e 17 self.assertEqual(pp._titleregex, r'(?P<title>.+)\ \-\ (?P<artist>.+)')