add assertion

This commit is contained in:
rolux 2011-10-11 21:19:54 +02:00
parent 90e5e4e932
commit d8c371e7fb

View file

@ -33,7 +33,7 @@ ASIAN_NAMES = [
]
PREFIXES = [
'al', 'da', 'de', 'del', 'dem', 'den', 'der', 'di', 'dos', 'du',
'e', 'el', 'la', 'the', 'van', 'vom', 'von', 'y', 'zu'
'e', 'el', 'la', 'san', 'the', 'van', 'vom', 'von', 'y', 'zu'
]
MIDFIXES = ['und']
SUFFIXES = ['ii', 'iii', 'jr', 'jr.', 'ph.d.', 'phd', 'sr', 'sr.']
@ -62,6 +62,9 @@ def get_sort_name(name):
>>> get_sort_name('Bing Wang')
'Wang Bing'
>>> get_sort_name('Frank Capra III')
'Capra III, Frank'
>>> get_sort_name('The Queen of England')
'Queen of England, The'