Changeset 6f7140f
- Timestamp:
- 08/29/10 11:23:45 (3 years ago)
- Branches:
- master
- Children:
- e5279c4
- Parents:
- 00ad607
- git-author:
- Aurélien Bompard <aurelien@…> (08/29/10 11:23:45)
- git-committer:
- Aurélien Bompard <aurelien@…> (08/29/10 11:23:45)
- Files:
-
- 2 edited
-
tests/test_paragraph.py (modified) (2 diffs)
-
xsl/document-content/paragraph.xsl (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
tests/test_paragraph.py
r61a9b94 r6f7140f 3 3 4 4 import unittest 5 import re 5 6 from lxml import etree 6 7 from . import xhtml2odt … … 41 42 self.assertEquals(odt, """<text:p text:style-name="Preformatted_20_Text">Test</text:p>""" 42 43 """<text:p text:style-name="Text_20_body"/>""") 44 45 def test_p_containing_dl(self): 46 html = '<html xmlns="http://www.w3.org/1999/xhtml"><p><dl><dt>Term</dt><dd>Value</dd></dl></p></html>' 47 odt = xhtml2odt(html) 48 print odt 49 self.assert_(re.match(""" 50 <table:table [^>]* > \s* 51 <table:table-column [^>]* /> \s* 52 <table:table-row> \s* 53 <table:table-cell [^>]* > \s* 54 <text:p[ ]text:style-name="Table_20_Contents">Term</text:p> \s* 55 </table:table-cell> \s* 56 <table:table-cell [^>]* > \s* 57 <text:p[ ]text:style-name="Table_20_Contents">Value</text:p> \s* 58 </table:table-cell> \s* 59 </table:table-row> \s* 60 </table:table> \s* 61 """, odt, re.X)) 43 62 44 63 def test_p_containing_text_and_block(self): -
xsl/document-content/paragraph.xsl
r70e8239 r6f7140f 66 66 child::h:blockquote| 67 67 child::h:pre | 68 child::h:dl | 68 69 child::h:div 69 70 "> … … 73 74 child::h:blockquote | 74 75 child::h:pre | 76 child::h:dl | 75 77 child::h:div 76 78 ">
Note: See TracChangeset
for help on using the changeset viewer.
