예제 #1
0
파일: edit_test.py 프로젝트: tantalor/emend
 def mock_content():
   return html.clean("pirate ninja robot “spam” should be “eggs”")
예제 #2
0
파일: html_test.py 프로젝트: tantalor/emend
 def test_clean(self):
   """Strip all tags and decode html entities to unicode code points."""
   encoded = '<p>From the Latin <i>emendare</i>, &#x201c;to free from fault.&rdquo;</p>'
   decoded = u'From the Latin emendare, \u201cto free from fault.\u201d'
   self.assertEquals(clean(encoded), decoded)
예제 #3
0
파일: edit_test.py 프로젝트: tantalor/emend
 def mock_content():
   return html.clean("pirate ninja robot &ldquo;ninja&rdquo; should be &ldquo;zombie&rdquo;")