Trees | Indices | Help |
|
---|
|
1 #!/usr/bin/env python 2 # -*- coding: utf-8 -*- 3 4 """tests decoration handling functions that are used by checks""" 5 6 from translate.filters import prefilters 79 string = "Nothing in here." 10 filtered = prefilters.filterwordswithpunctuation(string) 11 assert filtered == string 12 # test listed words (start / end with apostrophe) 13 string = "'n Boom het 'n tak." 14 filtered = prefilters.filterwordswithpunctuation(string) 15 assert filtered == "n Boom het n tak." 16 # test words containing apostrophe 17 string = "It's in it's own place." 18 filtered = prefilters.filterwordswithpunctuation(string) 19 assert filtered == "Its in its own place." 20 # test strings in unicode 21 string = u"Iṱ'š" 22 filtered = prefilters.filterwordswithpunctuation(string) 23 assert filtered == u"Iṱš"24
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Wed Mar 26 12:49:39 2008 | http://epydoc.sourceforge.net |