put space before colon
This commit is contained in:
@@ -45,8 +45,9 @@ class PathFilter(object):
|
||||
path = re.sub(r'[/\\]', '-', path, re.UNICODE)
|
||||
|
||||
def separators(path):
|
||||
# replace separators with a hyphen
|
||||
path = re.sub(r'[:\|]', '-', path, re.UNICODE)
|
||||
# replace separators with a space-hyphen or hyphen
|
||||
path = re.sub(r'[:]', ' -', path, re.UNICODE)
|
||||
path = re.sub(r'[\|]', '-', path, re.UNICODE)
|
||||
return path
|
||||
|
||||
# change all fancy single/double quotes to normal quotes
|
||||
|
||||
@@ -17,9 +17,14 @@ class FilterTestCase(common.TestCase):
|
||||
|
||||
def testFat(self):
|
||||
part = u'A Word: F**k you?'
|
||||
self.assertEquals(self._filter.filter(part), u'A Word- F__k you_')
|
||||
self.assertEquals(self._filter.filter(part), u'A Word - F__k you_')
|
||||
|
||||
def testSpecial(self):
|
||||
part = u'<<< $&*!\' "()`{}[]spaceship>>>'
|
||||
self.assertEquals(self._filter.filter(part),
|
||||
u'___ _____ ________spaceship___')
|
||||
|
||||
def testGreatest(self):
|
||||
part = u'Greatest Ever! Soul: The Definitive Collection'
|
||||
self.assertEquals(self._filter.filter(part),
|
||||
u'Greatest Ever_ Soul - The Definitive Collection')
|
||||
|
||||
Reference in New Issue
Block a user