예제 #1
0
 def t_handle_certain_symbols(self, raw, cooked):
     assert Name.clean(raw) == cooked
예제 #2
0
 def t_ignore_most_symbols(self, raw):
     assert Name.clean(raw) == "mr eric praline"
예제 #3
0
 def t_colons_and_commas(self, raw):
     assert Name.clean(raw) == "praline, mr eric"
예제 #4
0
 def t_drop_spacing(self, raw):
     assert Name.clean(raw) == "mr eric praline"
예제 #5
0
 def t_drop_emoji(self, raw):
     name = Name()
     assert name.clean(name._pre_clean(raw)) == "spiny norman"
예제 #6
0
 def t_strip_margin_hyphens(self, raw, cooked):
     assert Name.clean(raw) == cooked